Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # https://technology.jana.com/2016/04/26/challenge-your-python-knowledge/
- # 1 - iterator object evals as true, but is empty
- mystery = iter('')
- # 2 - double precision does not allow counting in 1-increments up to inf.
- # probably something like 1e18 could be enough that x+1 == x
- mystery1 = 1
- mystery2 = 1e308
- # 3 - self-referential dict
- mystery1 = {}
- mystery2 = {}
- mystery1['self'] = mystery1
- mystery2['self'] = mystery2
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement