« first day (3442 days earlier)      last day (46 days later) » 

2:57 PM
I guess the only workaround would be something like:
```
Real = typing.Union[int, float, Fraction]
Dec = typing.Union[int, Decimal]
```
And then for every function/method, I would have to do:
```
@typing.overload
def add(a: Real, b: Real) -> Real:
...

@typing.overload
def add(a: Dec, b: Dec) -> Dec:
...

def add(a, b):
pass
```
?
3:18 PM
1 message moved from Python
 
2 hours later…
5:09 PM
def check_answer(answer, guess):
if answer == guess:
print("CORRECT!")
return 1
else:
print("WRONG!")
return 0
1 message moved from Python

« first day (3442 days earlier)      last day (46 days later) »