Skip to content

Commit 35a2ed7

Browse files
committed
Adding URL for reference
Adding URL of sliding window technique for reference
1 parent b29847c commit 35a2ed7

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

data_structures/sliding_window/longest_substring_two_distinct.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
def length_of_longest_substring_two_distinct(s):
22
"""
3-
Finds the length of the longest substring with at most two distinct characters.
3+
Finds the length of the longest substring with at most two distinct characters.[https://www.geeksforgeeks.org/window-sliding-technique/]
4+
45
56
Args:
67
s (str): The input string.

data_structures/sliding_window/max_sum_subarray.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
def max_sum_subarray(arr, k):
22
"""
3-
Finds the maximum sum of a subarray of length k within the given array.
3+
Finds the maximum sum of a subarray of length k within the given array.[https://www.geeksforgeeks.org/window-sliding-technique/]
44
55
Args:
66
arr (list): The input array.

data_structures/sliding_window/min_subarray_len.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
def min_subarray_len(target, nums):
22
"""
3-
Finds the minimal length of a contiguous subarray of which the sum is at least the target.
3+
Finds the minimal length of a contiguous subarray of which the sum is at least the target.[https://www.geeksforgeeks.org/window-sliding-technique/]
4+
45
56
Args:
67
target (int): The target sum.

0 commit comments

Comments
 (0)