Skip to content

[mypy] Add/fix type annotations for binary trees in data structures #4085

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

Leo-LiHao
Copy link
Contributor

@Leo-LiHao Leo-LiHao commented Dec 31, 2020

$ mypy --strict data_structures/binary_tree/treap.py data_structures/binary_tree/lazy_segment_tree.py data_structures/binary_tree/binary_search_tree_recursive.py 
Success: no issues found in 3 source files

Related Issue: #4052

Describe your change:

  • Add an algorithm?
  • Fix a bug or typo in an existing algorithm?
  • Documentation change?

Checklist:

  • I have read CONTRIBUTING.md.
  • This pull request is all my own work -- I have not plagiarized.
  • I know that pull requests will not be merged if they fail the automated tests.
  • This PR only changes one algorithm file. To ease review, please open separate PRs for separate algorithms.
  • All new Python files are placed inside an existing directory.
  • All filenames are in all lowercase characters with no spaces or dashes.
  • All functions and variable names follow Python naming conventions.
  • All function parameters and return values are annotated with Python type hints.
  • All functions have doctests that pass the automated testing.
  • All new algorithms have a URL in its comments that points to Wikipedia or other similar explanation.
  • If this pull request resolves one or more open issues then the commit message contains Fixes: #{$ISSUE_NO}.

@ghost
Copy link

ghost commented Dec 31, 2020

Multiple Pull Request Detected

@Leo-LiHao, we are extremely excited that you want to submit multiple algorithms in this repository but we have a limit on how many pull request a user can keep open at a time. This is to make sure all maintainers and users focus on a limited number of pull requests at a time to maintain the quality of the code.

This pull request is being closed as the user already has an open pull request. Please focus on your previous pull request before opening another one. Thank you for your cooperation.

User opened pull requests (including this one): #4085, #4001

@ghost ghost added the awaiting reviews This PR is ready to be reviewed label Dec 31, 2020
@ghost ghost closed this Dec 31, 2020
@dhruvmanila dhruvmanila reopened this Dec 31, 2020
@ghost ghost added the enhancement This PR modified some existing files label Dec 31, 2020
@dhruvmanila dhruvmanila changed the title [mypy] Add/fix type annotations for binary trees in data structures #4056 [mypy] Add/fix type annotations for binary trees in data structures Dec 31, 2020
Copy link
Member

@poyea poyea left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your pull request!🤩

@ghost ghost removed the awaiting reviews This PR is ready to be reviewed label Feb 4, 2021
@poyea poyea merged commit 2595cf0 into TheAlgorithms:master Feb 4, 2021
l3str4nge pushed a commit that referenced this pull request Feb 20, 2021
Co-authored-by: goodm2 <4qjpngu8mem8cz>
MatthewG25 pushed a commit to MatthewG25/Python that referenced this pull request Feb 21, 2021
MatthewG25 added a commit to MatthewG25/Python that referenced this pull request Feb 22, 2021
MatthewG25 added a commit to MatthewG25/Python that referenced this pull request Feb 22, 2021
MatthewG25 added a commit to MatthewG25/Python that referenced this pull request Feb 22, 2021
MatthewG25 added a commit to MatthewG25/Python that referenced this pull request Feb 22, 2021
l3str4nge pushed a commit that referenced this pull request Feb 23, 2021
* [mypy] Add/fix type annotations for recursive_insertion_sort(#4085)

* [mypy] Add/fix type annotations for bucket_sort(#4085)

* [mypy] Reworked code for cocktail_shaker_sort so that missing return statement error is resolved(#4085)

* [mypy] Add/fix type annotations for patience_sort(#4085)

* [mypy] Add/fix type annotations for radix_sort(#4085)

Co-authored-by: goodm2 <4qjpngu8mem8cz>
peRFectBeliever pushed a commit to peRFectBeliever/Python that referenced this pull request Apr 1, 2021
…heAlgorithms#4085)

* fix mypy: data_structures:binary_tree

* mypy --strict for binary_trees in data_structures

* fix pre-commit

Co-authored-by: LiHao <[email protected]>
peRFectBeliever pushed a commit to peRFectBeliever/Python that referenced this pull request Apr 1, 2021
peRFectBeliever pushed a commit to peRFectBeliever/Python that referenced this pull request Apr 1, 2021
…4224)

* [mypy] Add/fix type annotations for recursive_insertion_sort(TheAlgorithms#4085)

* [mypy] Add/fix type annotations for bucket_sort(TheAlgorithms#4085)

* [mypy] Reworked code for cocktail_shaker_sort so that missing return statement error is resolved(TheAlgorithms#4085)

* [mypy] Add/fix type annotations for patience_sort(TheAlgorithms#4085)

* [mypy] Add/fix type annotations for radix_sort(TheAlgorithms#4085)

Co-authored-by: goodm2 <4qjpngu8mem8cz>
Panquesito7 pushed a commit to Panquesito7/Python that referenced this pull request May 13, 2021
…heAlgorithms#4085)

* fix mypy: data_structures:binary_tree

* mypy --strict for binary_trees in data_structures

* fix pre-commit

Co-authored-by: LiHao <[email protected]>
Panquesito7 pushed a commit to Panquesito7/Python that referenced this pull request May 13, 2021
Panquesito7 pushed a commit to Panquesito7/Python that referenced this pull request May 13, 2021
…4224)

* [mypy] Add/fix type annotations for recursive_insertion_sort(TheAlgorithms#4085)

* [mypy] Add/fix type annotations for bucket_sort(TheAlgorithms#4085)

* [mypy] Reworked code for cocktail_shaker_sort so that missing return statement error is resolved(TheAlgorithms#4085)

* [mypy] Add/fix type annotations for patience_sort(TheAlgorithms#4085)

* [mypy] Add/fix type annotations for radix_sort(TheAlgorithms#4085)

Co-authored-by: goodm2 <4qjpngu8mem8cz>
shermanhui pushed a commit to shermanhui/Python that referenced this pull request Oct 22, 2021
…heAlgorithms#4085)

* fix mypy: data_structures:binary_tree

* mypy --strict for binary_trees in data_structures

* fix pre-commit

Co-authored-by: LiHao <[email protected]>
shermanhui pushed a commit to shermanhui/Python that referenced this pull request Oct 22, 2021
shermanhui pushed a commit to shermanhui/Python that referenced this pull request Oct 22, 2021
…4224)

* [mypy] Add/fix type annotations for recursive_insertion_sort(TheAlgorithms#4085)

* [mypy] Add/fix type annotations for bucket_sort(TheAlgorithms#4085)

* [mypy] Reworked code for cocktail_shaker_sort so that missing return statement error is resolved(TheAlgorithms#4085)

* [mypy] Add/fix type annotations for patience_sort(TheAlgorithms#4085)

* [mypy] Add/fix type annotations for radix_sort(TheAlgorithms#4085)

Co-authored-by: goodm2 <4qjpngu8mem8cz>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement This PR modified some existing files
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants