Skip to content

Commit 018e02c

Browse files
authored
Merge branch 'master' into fix/linked-list-generator-contract
2 parents f1c37e3 + 14082f5 commit 018e02c

2 files changed

Lines changed: 5 additions & 8 deletions

File tree

‎data_structures/heap/heap.py‎

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,15 @@
22

33
from abc import abstractmethod
44
from collections.abc import Iterable
5-
from typing import Protocol, TypeVar
5+
from typing import Protocol
66

77

88
class Comparable(Protocol):
99
@abstractmethod
10-
def __gt__(self: T, other: T, /) -> bool:
10+
def __gt__(self, other: object, /) -> bool:
1111
pass
1212

1313

14-
T = TypeVar("T", bound=Comparable)
15-
16-
1714
class Heap[T: Comparable]:
1815
"""A Max Heap Implementation
1916

‎maths/zellers_congruence.py‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import argparse
2-
import datetime
2+
from datetime import date
33

44

55
def zeller(date_input: str) -> str:
@@ -119,8 +119,8 @@ def zeller(date_input: str) -> str:
119119
"Year out of range. There has to be some sort of limit...right?"
120120
)
121121

122-
# Get datetime obj for validation
123-
dt_ck = datetime.date(int(y), int(m), int(d))
122+
# Get date obj for validation
123+
dt_ck = date(int(y), int(m), int(d))
124124

125125
# Start math
126126
if m <= 2:

0 commit comments

Comments
 (0)