Skip to content

Commit 773e1b0

Browse files
authored
Improve grammar in linear_search docstring
Improved wording in the linear search docstring for better clarity. No code logic changed.
1 parent 3c88735 commit 773e1b0

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

searches/linear_search.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
"""
2-
This is pure Python implementation of linear search algorithm
2+
This is a pure Python implementation of the linear search algorithm.
33
44
For doctests run following command:
55
python3 -m doctest -v linear_search.py
@@ -11,9 +11,8 @@
1111

1212
def linear_search(sequence: list, target: int) -> int:
1313
"""A pure Python implementation of a linear search algorithm
14-
15-
:param sequence: a collection with comparable items (as sorted items not required
16-
in Linear Search)
14+
:param sequence: a collection with comparable items (sorting is not required for
15+
linear search)
1716
:param target: item value to search
1817
:return: index of found item or -1 if item is not found
1918

0 commit comments

Comments
 (0)