Commit Graph

3436 Commits

Author SHA1 Message Date
DIVYASREE S
9403de6894
Update proof_of_work.py 2024-10-10 22:46:12 +05:30
pre-commit-ci[bot]
5d87a84ca0 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2024-10-10 17:01:05 +00:00
DIVYASREE S
38904a32f7
Update proof_of_work.py 2024-10-10 22:30:29 +05:30
DIVYASREE S
1e3b382c5d
Update proof_of_work.py 2024-10-10 22:28:24 +05:30
pre-commit-ci[bot]
6ee3d9e1e6 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2024-10-10 16:50:29 +00:00
DIVYASREE S
d6ab438d90
Updated proof_of_work.py 2024-10-10 22:20:05 +05:30
pre-commit-ci[bot]
5e70415ced [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2024-10-10 16:45:32 +00:00
DIVYASREE S
cd42352303
Added proof_of_work.py 2024-10-10 22:14:01 +05:30
DIVYASREE S
8ad73811e5
Delete blockchain/proof_of_work.py 2024-10-10 22:04:33 +05:30
pre-commit-ci[bot]
44cb9a30f7 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2024-10-10 16:33:40 +00:00
DIVYASREE S
f55f9aba89
Updated proof_of_work.py 2024-10-10 22:03:33 +05:30
DIVYASREE S
9aa315441b
Updated proof_of_work.py 2024-10-10 22:01:48 +05:30
DIVYASREE S
390cd7e12e
Updated proof_of_work.py 2024-10-10 22:00:17 +05:30
pre-commit-ci[bot]
bbe09d7c4c [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2024-10-10 16:22:37 +00:00
DIVYASREE S
5a7b2ffbba
Updated proof_of_work.py 2024-10-10 21:52:14 +05:30
pre-commit-ci[bot]
bd89e9705f [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2024-10-10 16:20:58 +00:00
DIVYASREE S
374cbc2bf9
Created proof_of_work.py 2024-10-10 21:50:01 +05:30
DIVYASREE S
e14f6d5122
Updated proof_of_stake.py 2024-10-10 21:46:12 +05:30
pre-commit-ci[bot]
8b9ff8d4f3 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2024-10-10 16:12:09 +00:00
DIVYASREE S
df4c444095
Created and updated proof_of_stake.py 2024-10-10 21:40:33 +05:30
DIVYASREE S
b1c7d37812
Delete blockchain/proof_of_stake.py 2024-10-10 21:39:40 +05:30
pre-commit-ci[bot]
2046ea45bc [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2024-10-10 16:03:51 +00:00
DIVYASREE S
82064e3a23
Changes to proof_of_stake.py 2024-10-10 21:32:04 +05:30
pre-commit-ci[bot]
d770fa5bf5 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2024-10-10 15:54:31 +00:00
DIVYASREE S
28df0f3c9b
Updated proof_of_stake.py 2024-10-10 21:17:13 +05:30
DIVYASREE S
f467cec98a
Created proof_of_stake.py 2024-10-10 21:12:51 +05:30
Christian Clauss
e9e7c96465
Create GitHub Pages docs with Sphinx (#11888) 2024-10-08 19:09:28 +02:00
Jeel Rupapara
260e3d8b35
feat: add test cases in cipher's autokey (#11881) 2024-10-08 13:33:28 +02:00
pre-commit-ci[bot]
2d671df073
[pre-commit.ci] pre-commit autoupdate (#11874)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/pre-commit/pre-commit-hooks: v4.6.0 → v5.0.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.6.0...v5.0.0)
- [github.com/astral-sh/ruff-pre-commit: v0.6.8 → v0.6.9](https://github.com/astral-sh/ruff-pre-commit/compare/v0.6.8...v0.6.9)

* updating DIRECTORY.md

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <pre-commit-ci[bot]@users.noreply.github.com>
2024-10-07 22:49:29 +02:00
Lonercode
dba8eecb47
added gronsfeld cipher implementation (#11835)
* added gronsfeld cipher implementation

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* from string import ascii_uppercase

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update gronsfeld_cipher.py

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Christian Clauss <cclauss@me.com>
2024-10-07 11:58:07 +02:00
1227haran
cfd6d095f1
Added max_sum_bst.py (#11832)
* Added new algorithm

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated changes

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated filename

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated the code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated the code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated the code

* Updated code

* Updated code

* Updated code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated the code

* Updated code

* Updated code

* Updated code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated code

* updated

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated code

* Updated code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated code

* Updated code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated code

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Apply suggestions from code review

* Update maximum_sum_bst.py

* def max_sum_bst(root: TreeNode | None) -> int:

* def solver(node: TreeNode | None) -> tuple[bool, int, int, int]:

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Christian Clauss <cclauss@me.com>
2024-10-07 10:36:15 +02:00
Jeel Rupapara
3422ebc75b
feat: add testcase of polynom_for_points (#11811)
* feat: add testcase of polynom_for_points

* fix: remove the print from the testcase of points_to_polynomial

* fix: remove print statement from old test cases
2024-10-07 08:30:11 +02:00
Vineet Kumar
fcf82a1eda
Implemented Exponential Search with binary search for improved perfor… (#11666)
* Implemented Exponential Search with binary search for improved performance on large sorted arrays.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Added type hints and doctests for binary_search and exponential_search functions. Improved code documentation and ensured testability.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update and rename Exponential_Search.py to exponential_search.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-10-05 10:34:48 -07:00
Andrey Ivanov
ad6395d340
Update ruff usage example in CONTRIBUTING.md (#11772)
* Update ruff usage example

* Update CONTRIBUTING.md

Co-authored-by: Tianyi Zheng <tianyizheng02@gmail.com>

---------

Co-authored-by: Tianyi Zheng <tianyizheng02@gmail.com>
2024-10-05 10:24:58 -07:00
Jeel Rupapara
50aca04c67
feat: increase test coverage of longest_common_subsequence to 75% (#11777) 2024-10-05 10:21:43 -07:00
1227haran
5a8655d306
Added new algorithm to generate numbers in lexicographical order (#11674)
* Added algorithm to generate numbers in lexicographical order

* Removed the test cases

* Updated camelcase to snakecase

* Added doctest

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Added descriptive name for n

* Reduced the number of letters

* Updated the return type

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Updated import statement

* Updated return type to Iterator[int]

* removed parentheses

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-10-05 10:19:58 -07:00
ARNAV RAJ
9a572dec2b
feat: Implemented Matrix Exponentiation Method (#11747)
* feat: add Matrix Exponentiation method
docs: updated the header documentation and added new documentation for
the new function.

* feat: added new function matrix exponetiation method

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* feat: This function uses the tail-recursive form of the Euclidean algorithm to calculate

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* reduced the number of characters per line in the comments

* removed unwanted code

* feat: Implemented a new function to swaap numbers without dummy variable

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* removed previos code

* Done with the required changes

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Done with the required changes

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Done with the required changes

* Done with the required changes

* Done with the required changes

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update maths/fibonacci.py

Co-authored-by: Tianyi Zheng <tianyizheng02@gmail.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Done with the required changes

* Done with the required changes

* Done with the required changes

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Tianyi Zheng <tianyizheng02@gmail.com>
2024-10-04 09:29:39 -07:00
Lonercode
59ff87dc55
Added doctests to min_cost_string_conversion.py and removed :c specifier (#11721)
* Added doctests to min_cost_string_conversion.py and removed :c specifier

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* resolved line length issues based on ruff requirements

* modified in compliance with ruff for line length

* Update strings/min_cost_string_conversion.py

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Tianyi Zheng <tianyizheng02@gmail.com>
2024-10-04 02:36:14 -07:00
Sai Aswin Madhavan
917ad62105
Removed incorrect type hints (#11711) 2024-10-04 02:28:50 -07:00
Hardik Pawar
e20b503b24
Improve comments, add doctests for kahns_algorithm_topo.py (#11668)
* Improve comments, add doctests for kahns_algorithm_topo.py

* Improve function docstring

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Rename variables, remove print

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-10-04 02:06:08 -07:00
JeevaRamanathan
40f65e8150
Improve comments, docstrings in next_greatest_element.py (#11685)
* Improve comments in next_greatest_element.py

Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>

* few changes

Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>

* updated descriptions of the functions parameters

Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>

---------

Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
2024-10-02 17:18:01 -07:00
Aswin P Kumar
080e7903a0
Add Word Break algorithm (#11687)
* Add Word Break algorithm

* Add Word Break algorithm

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-10-02 17:03:48 -07:00
Ali Rashid
f4b4ac159a
Adding Doctests to floyd_warshall.py (#11690)
* Ruff test resolution

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-10-02 16:54:56 -07:00
1227haran
918fa8bb8a
Optimized O(n) to O(1) (#11669) 2024-10-02 11:07:07 -07:00
Hardik Pawar
00e9d86224
Improve comments, add doctests in symmetric_tree.py (#11619) 2024-10-01 19:54:12 -07:00
Hardik Pawar
43a47e01eb
Add word ladder algorithm in backtracking (#11590)
* Add word ladder algorithm in backtracking

* Improve comments and implement ruff checks

* updating DIRECTORY.md

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Change BFS to Backtracking

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Incorporate PR Changes

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Add type hints for backtrack function

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Hardvan <Hardvan@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-10-01 19:48:17 -07:00
Christian Clauss
0abeeab39f
Drop six from our GitHub Actions (#11621)
Drop https://six.readthedocs.io
2024-10-01 17:32:31 +02:00
Christian Clauss
0177ae1cd5
Upgrade to Python 3.13 (#11588) 2024-09-30 23:01:15 +02:00
pre-commit-ci[bot]
a7bfa22455
[pre-commit.ci] pre-commit autoupdate (#11594)
updates:
- [github.com/astral-sh/ruff-pre-commit: v0.6.7 → v0.6.8](https://github.com/astral-sh/ruff-pre-commit/compare/v0.6.7...v0.6.8)
- [github.com/abravalheri/validate-pyproject: v0.19 → v0.20.2](https://github.com/abravalheri/validate-pyproject/compare/v0.19...v0.20.2)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-09-30 22:16:17 +02:00
Christian Clauss
a9ca110d6b
Scripts for closing pull requests for Hacktoberfest (#11587)
* Scripts for closing pull requests for Hacktoberfest

* --limit=500

* Lose 2024
2024-09-30 12:49:31 +02:00