Grande Finale of Date and Time SOLVED!


#1

Hi. I am brand new to this, and I'm a kid. I am getting stuck on Grade Finale of the Date and Time section.

I've tried multiple suggested codes on this board, none of which have worked. I have even copied and pasted the example. What am I missing?? Or is this some kind of glitch?

This is my code:

from datetime import datetime
now = datetime.now(

print '%s/%s/%s %s:&s:%s' % (now.month, now.day, now.year, now.hour, now.minute, now.second)

Thank you in advance for your help.

Ace

`


#2

Please show your code. We can't help unless we have code


#3

Just added! Thank you!


#4

Hi ace, in now + datetime.now(, you need to close the parenthesis. it should look like this:now =datetime.now()`


#5

Thank you. It tried, still didn't work. What am i missing?

from datetime import datetime
now = datetime.now()

print '%s/%s/%s %s:&s:%s' % (now.month, now.day, now.year, now.hour, now.minute, now.second)


#6

Actually, got it! saw my mistake! @

thank you!


#7

Hi ace:

in the last part, try making it into (now.year, now.month, now.day, now.hour, now.minute,now.second)

switch the order around.


#9