-
-
Notifications
You must be signed in to change notification settings - Fork 47k
Add typing to data_structures/hashing/hash_table.py #7040
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
Conversation
charge_factor: int | None = None, | ||
lim_charge: float | None = None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Python and mypy can figure this out and it is a suggestion to the caller to pass in an int and not pass in None
.
charge_factor: int | None = None, | |
lim_charge: float | None = None, | |
charge_factor: int = None, | |
lim_charge: float = None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
makes sense, but code legibility changes, since it's optional.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@cclauss if you have a strong opinion, i can change - but personally this looks more legible is all. :)
requesting review if someone can please take a look. thanks in advance! |
@cclauss can you please add hacktoberfest-accepted label? |
Describe your change:
Checklist:
Fixes: #{$ISSUE_NO}
.