Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import time
- class SmoothCacheTime(int):
- def __new__(cls, value=None):
- if value is None:
- value = time.time()
- i = int.__new__(cls, value)
- return i
- i = SmoothCacheTime()
- print i
- print isinstance(i, SmoothCacheTime)
Add Comment
Please, Sign In to add comment