The repeated code jumps out, right away. Two lines can be removed from the top. Going to try to test the (repaired) code but it would sure be easier if you pasted it in so we could capture it.
Tested and passes.
== discussions / opinions=
python datetime.now() explained site:stackoverflow.com
Also tested and passed...
from datetime import datetime now = datetime.now() now_tuple = (now.month,now.day,now.year,now.hour,now.minute,now.second) now_format = "%s/%s/%s %s:%s:%s" print now_format % now_tuple
OR in different format...
from datetime import datetime now = datetime.now() now_tuple = (now.month,now.day,now.year,now.hour,now.minute,now.second) now_format = "%s/%s/%s %d:%02d:%02d" print now_format % now_tuple
Hello I was also having problems with the date time grand finale so I see that the code you wrote works, but I don't understand the tuple because the instructions never mention that part of the tuple. can you please explain your way. thank you
Sir, can you give us your version to explain tuple? Kindly APPRECIATED!
What part of the above documentation do you not understand? I don't have my own version since the docs are largely sufficient explanation. What can I add?
no problem sir. i understand!
I was doing the same thing... use now.day instead of now.date and it will work.