KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
If I use from time import time , Python does not recognize time.sleep(60) . But if I use import time , then Python does not recognize t=time() . Why does this happen? Is there any way I can use time() and time.sleep(x) in the same program? from time import time #import time intervalInMinute = 1 t = time() while 1: time.sleep(60) The kind of error I get is: Traceback (most recent call last): File "myProg.py", line 9, in <module> time.sleep(60) AttributeError: 'builtin_function_or_method' object has no attribute 'sleep'
Tags (comma-separated)
Save Edits
Cancel