0

What is the need to write fib.get(4,0)? Can't we just write fib.get(4)

6th Apr 2016, 5:38 AM
Dhiranjan
1 Answer
+ 2
No, if there's not key 4, then fib.get(4) will return "None", but not 0.This will lead to a TypeError.
14th Apr 2016, 6:07 AM
Chow Hong (ALias77)
Chow Hong (ALias77) - avatar