How do I get my program to enter the current date and time without me entering it | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

How do I get my program to enter the current date and time without me entering it

30th Aug 2018, 3:17 PM
Caitlin
3 Answers
+ 3
Check out the Python "time" module. time.ctime() will give you current time and date according to you time zone in string. Don't forget to import it first.
30th Aug 2018, 3:34 PM
Шащи Ранжан
Шащи Ранжан - avatar
+ 3
you need to learn datetime module check it. https://youtu.be/eirjjyP2qcQ
30th Aug 2018, 4:00 PM
Maninder $ingh
Maninder $ingh - avatar
0
import time time.time()
30th Aug 2018, 3:31 PM
Markus Kaleton
Markus Kaleton - avatar