Commit Graph

21 Commits

Author SHA1 Message Date
Christian Clauss
6acd7fb5ce
Wrap lines that go beyond GitHub Editor (#1925)
* Wrap lines that go beyond GiHub Editor

* flake8 --count --select=E501 --max-line-length=127

* updating DIRECTORY.md

* Update strassen_matrix_multiplication.py

* fixup! Format Python code with psf/black push

* Update decision_tree.py

Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
2020-05-01 23:36:35 +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
onlinejudge95
2cb6a6523e
Corrects failing check in master (#1676) 2020-01-12 14:58:47 +05:30
AlexLeka98
98733618e2 Added Strassen divide and conquer algorithm to multiply matrices. (#1648)
* Added Strassen divide and conquer algorithm to multiply matrices

* Divide and conquer algorith to calculate pow(a,b) or a raised to the power of b

* Putting docstring inside the function.

* Added doctests
2020-01-12 09:34:10 +05:30
ELNS
43905efe29 Adding doctests into LDA algorithm (#1621)
* Adding doctests into <gaussian_distribution> function

* Adding doctests into <y_generator> function

* Adding doctests into <calculate_mean> function

* Adding doctests into <calculate_probabilities> function

* Adding doctests into <calculate_variance> function

* Adding doctests into <predict_y_values> function

* Adding doctests into <accuracy> function

* fixup! Format Python code with psf/black push

* Update convex_hull.py

* Update convex_hull.py
2019-12-08 23:15:17 +01:00
Christian Clauss
26b0803319
Simplify sudoku.is_completed() using builtin all() (#1608)
* Simplify sudoku.is_completed() using builtin all()

Simplify __sudoku.is_completed()__ using Python builtin function [__all()__](https://docs.python.org/3/library/functions.html#all).

* fixup! Format Python code with psf/black push

* Update sudoku.py

* fixup! Format Python code with psf/black push

* Old style exception -> new style for Python 3

* updating DIRECTORY.md

* Update convex_hull.py

* fixup! Format Python code with psf/black push

* e.args[0] = "msg"

* ValueError: could not convert string to float: 'pi'

* Update convex_hull.py

* fixup! Format Python code with psf/black push
2019-12-08 22:42:17 +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
Ankur Chattopadhyay
7592cba417 psf/black code formatting (#1421)
* added sol3.py for problem_20

* added sol4.py for problem_06

* ran `black .` on `\Python`
2019-10-22 19:13:48 +02:00
Jigyasa G
b6cc37d461 mergesort added (#1313)
* mergesort added

* added doctest
2019-10-10 00:12:09 +05:00
William Zhang
9eac17a408 psf/black code formatting (#1277) 2019-10-05 10:14:13 +05:00
Denis Trofimov
04962c0d17 Fix lgtm error display #1024 (#1190)
* fix: Syntax Error lgtm display in matrix/matrix_operation.py.

* Testing for None should use the 'is' operator.

* fix: Too many arguments for string format.

* fix: supress lgtm alert as false positive.

* style: Unnecessary 'pass' statement.

* Revert "fix: Syntax Error lgtm display in matrix/matrix_operation.py."

This reverts commit 4c629b4ce1.
2019-09-21 16:23:34 +02:00
Maxwell Aladago
a4ed40be86 changing typo (#1168) 2019-09-04 22:06:44 +02: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
Maxwell Aladago
05c9a05f36 ENH: two algorithms for the convex hull problem of a set of 2d points on a plain (#1135)
* divide and conquer and brute force algorithms for array-inversions counting

* divide and conquer and brute force algorithms for array-inversions counting

* divide and conquer and brute force algorithms for array-inversions counting

* a naive and divide-and-conquer algorithms for the convex-hull problem

* two convex-hull algorithms, a divide-and-conquer and a naive algorithm

* two convex-hull algorithms, a divide-and-conquer and a naive algorithm

* two convex-hull algorithms, a divide-and-conquer and a naive algorithm
2019-08-17 17:36:31 +02:00
Maxwell Aladago
5bdcd4836c EHN: A divide-and-conquer, and brute-force algorithms for array inversions co… (#1133)
* divide and conquer and brute force algorithms for array-inversions counting

* divide and conquer and brute force algorithms for array-inversions counting

* divide and conquer and brute force algorithms for array-inversions counting
2019-08-15 20:07:43 +02:00
Harshil
762482dc40 Update closest_pair_of_points.py (#1109) 2019-08-06 21:31:03 +02:00
rsun0013
58126406fd pytests for closest_pair_of_points.py (#1099)
added some tests to the file
2019-08-06 11:17:17 +02:00
Dharni0607
c85312da89 updates in closest pair of points algorithm (#979)
* updated closest pair of points (n*(logn)^2) to (n*logn)
2019-07-09 19:50:43 +04:30
Erfan Alimohammadi
781b7f86e7 Fix readme and duplicate (#967)
* Fix typo

* Add all_permutations algorithm to backtracking directory

* Update backtracking and D&C algorithms in README

Update backtracking and divide_and_conquer algorithms in README

* Remove the duplicated file
2019-07-06 20:02:06 +05:30
Dharni0607
035457f569 closest pair of points algo (#943)
* created divide_and_conquer folder and added max_sub_array_sum.py under it (issue #817)

* additional file in divide_and_conqure (closest pair of points)
2019-07-04 12:19:14 +04:30
Dharni0607
0f56ab5c3c Divide and conquer Algorithms Issue#817 (#938)
* add ons in string directory - Bayer_Moore_Search

* created divide_and_conquer folder and added max_sub_array_sum.py under it (issue #817)
2019-07-02 16:50:25 +04:30