Commit Graph

14 Commits

Author SHA1 Message Date
Almas Bekbayev
8cce9cf066
Fix linear_search docstring return value (#8644) 2023-07-30 18:32:05 -07:00
Ashley Jeji George
799fde4c07
Update linear_search.py (#2422)
* Update linear_search.py

Python implementation of recursive linear search algorithm

* Update linear_search.py

Added different doctests
Added the parameter hints
Handled the exception

* Update linear_search.py

added parameter hints to linear_search

* Update linear_search.py

Both the functions return the index if the target is found and -1 if it is not found
The rec_linear_search raises an exception if there is an indexing problem
Made changes in the doc comments

* Update linear_search.py

Co-authored-by: Christian Clauss <cclauss@me.com>
2020-09-14 12:44:46 +02:00
Christian Clauss
9316e7c014
Set the Python file maximum line length to 88 characters (#2122)
* flake8 --max-line-length=88

* fixup! Format Python code with psf/black push

Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
2020-06-16 10:09:19 +02:00
Himanshu Airan
48bb14d4b2
Update linear_search.py (#1974)
* Update linear_search.py

Comment modified in line 17 as Sorting not required in Linear Search

* Update linear_search.py

Comment modified in line 17
2020-05-14 16:52:43 +02:00
Prince Gangurde
58271c5851
Update linear_search.py (#1906) 2020-04-24 12:34:18 +02:00
matkosoric
7f04e5cd34
contribution guidelines checks (#1787)
* spelling corrections

* review

* improved documentation, removed redundant variables, added testing

* added type hint

* camel case to snake case

* spelling fix

* review

* python --> Python # it is a brand name, not a snake

* explicit cast to int

* spaces in int list

* "!= None" to "is not None"

* Update comb_sort.py

* various spelling corrections in documentation & several variables naming conventions fix

* + char in file name

* import dependency - bug fix

Co-authored-by: John Law <johnlaw.po@gmail.com>
2020-03-04 13:40:28 +01:00
GeorgeChambi
9eb50cc223 Improved readability (#1615)
* improved readability

* further readability improvements

* removed csv file and added f
2019-12-07 06:39:59 +01:00
William Zhang
9eac17a408 psf/black code formatting (#1277) 2019-10-05 10:14:13 +05:00
Christian Clauss
47a9ea2b0b
Simplify code by dropping support for legacy Python (#1143)
* Simplify code by dropping support for legacy Python

* sort() --> sorted()
2019-08-19 15:37:49 +02:00
overclockedllama
dd9f0b3f2e fix comma spelling from coma to comma (#722) 2019-02-27 22:33:29 +08:00
cclauss
4e06949072 Modernize Python 2 code to get ready for Python 3 2017-11-25 10:23:50 +01:00
KyleScharnhorst
014786e340 Fix: typo in multiple files. 2017-10-07 06:47:50 -07:00
NotAName
7bdcd08996 Fixed typo in linear_search.py
The documentation comment said "binary search", not "linear search"
2016-08-30 21:06:49 +02:00
Sergey Tsaplin
ab2614574e Move files to separate directories 2016-08-01 15:06:53 +05:00