-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Updation in MaxHeap.py #156
Comments
Maki200320
added a commit
to Maki200320/Python
that referenced
this issue
Apr 28, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Naming Conventions: Renamed private methods to follow Python's naming conventions (snake_case).
Returning None: Changed the return value of peek and pop methods to None instead of False for clarity. In Python, None is typically used to indicate the absence of a value.
Use of Dummy Element: Initialized the heap with a dummy element at index 0 to simplify index calculations. This helps in avoiding special cases in the code.
Output Formatting: Changed the output printing to exclude the dummy element when printing the heap elements.
The text was updated successfully, but these errors were encountered: