Commit Graph

10 Commits

Author SHA1 Message Date
Christian Clauss
cecf43d648
Pyupgrade to Python 3.9 (#4718)
* Pyupgrade to Python 3.9

* updating DIRECTORY.md

Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
2021-09-07 13:37:03 +02:00
Hao LI
2595cf059d
[mypy] Add/fix type annotations for binary trees in data structures (#4085)
* fix mypy: data_structures:binary_tree

* mypy --strict for binary_trees in data_structures

* fix pre-commit

Co-authored-by: LiHao <leo_how@163.com>
2021-02-05 00:59:38 +08:00
Christian Clauss
9200a2e543
from __future__ import annotations (#2464)
* from __future__ import annotations

* fixup! from __future__ import annotations

* fixup! from __future__ import annotations

* fixup! Format Python code with psf/black push

Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
2020-09-23 13:30:13 +02:00
kanthuc
f8c57130f2
lazy_segment_tree.py-style-fixes (#2347)
* fixed variable naming and unnecessary type hints

* print(segt)

Co-authored-by: Christian Clauss <cclauss@me.com>
2020-08-24 09:52:02 +02:00
kanthuc
2eaacee7b4
lowest_common_ancestor.py static type checking (#2329)
* adding static type checking to basic_binary_tree.py

* Add static type checking to functions with None return type

* Applying code review comments

* Added missing import statement

* fix spaciing

* "cleaned up depth_of_tree"

* Add doctests and then streamline display() and is_full_binary_tree()

* added static typing to lazy_segment_tree.py

* added missing import statement

* modified variable names for left and right elements

* added static typing to lowest_common_ancestor.py

* fixed formatting

* modified files to meet style guidelines, edited docstrings and added some doctests

* added and fixed doctests in lazy_segment_tree.py

* fixed errors in doctests

Co-authored-by: Christian Clauss <cclauss@me.com>
2020-08-21 06:54:34 +02:00
Christian Clauss
1f8a21d727
Tighten up psf/black and flake8 (#2024)
* Tighten up psf/black and flake8

* Fix some tests

* Fix some E741

* Fix some E741

* updating DIRECTORY.md

Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
2020-05-22 08:10:11 +02: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
Christian Clauss
89acf5d017 print() is a function just like every other function (#1101)
* print() is a function just like every other function
2019-08-06 12:14:23 +02:00
Hector S
05e5172093 .vs/ directory, matrix_multiplication_addition file and binary tree directory (#894)
* Added print function into matrix_multiplication_addition.py and removed blank space in data_structures/binary tree directory

* Removed .vs/ folder per #893

* Rename matrix_multiplication_addition.py to matrix_operation.py
2019-06-11 19:24:53 +08:00