Flake8: Drop ignore of issue A003 (#7949)

* Flake8: Drop ignore of issue A003

* updating DIRECTORY.md

Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
This commit is contained in:
Christian Clauss
2022-11-02 19:20:45 +01:00
committed by GitHub
parent 598f6a26a1
commit 45b3383c39
9 changed files with 42 additions and 62 deletions

View File

@ -88,13 +88,6 @@ class Heap:
for i in range(self.heap_size // 2 - 1, -1, -1):
self.max_heapify(i)
def max(self) -> float:
"""return the max in the heap"""
if self.heap_size >= 1:
return self.h[0]
else:
raise Exception("Empty heap")
def extract_max(self) -> float:
"""get and remove max from heap"""
if self.heap_size >= 2: