Skip to content

Commit 3a1cdd9

Browse files
updated descriptions of the functions parameters
Signed-off-by: JeevaRamanathan <[email protected]>
1 parent 7e905ad commit 3a1cdd9

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

data_structures/stacks/next_greater_element.py

+6-6
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ def next_greatest_element_slow(arr: list[float]) -> list[float]:
1313
of O(n^2), where n is the size of the array.
1414
1515
Args:
16-
arr (list[float]): List of numbers for which the NGE is calculated.
16+
arr: List of numbers for which the NGE is calculated.
1717
1818
Returns:
19-
list[float]: List containing the next greatest elements. If no
19+
List containing the next greatest elements. If no
2020
greater element is found, -1 is placed in the result.
2121
2222
Example:
@@ -47,10 +47,10 @@ def next_greatest_element_fast(arr: list[float]) -> list[float]:
4747
it still has a time complexity of O(n^2).
4848
4949
Args:
50-
arr (list[float]): List of numbers for which the NGE is calculated.
50+
arr: List of numbers for which the NGE is calculated.
5151
5252
Returns:
53-
list[float]: List containing the next greatest elements. If no
53+
List containing the next greatest elements. If no
5454
greater element is found, -1 is placed in the result.
5555
5656
Example:
@@ -80,10 +80,10 @@ def next_greatest_element(arr: list[float]) -> list[float]:
8080
greatest element for each element.
8181
8282
Args:
83-
arr (list[float]): List of numbers for which the NGE is calculated.
83+
arr: List of numbers for which the NGE is calculated.
8484
8585
Returns:
86-
list[float]: List containing the next greatest elements. If no
86+
List containing the next greatest elements. If no
8787
greater element is found, -1 is placed in the result.
8888
8989
Example:

0 commit comments

Comments
 (0)