Published
- 1 min read
python date
The solution for this is noted below
python date
Solution
from datetime import datetime
date = datetime.now().strftime("%d%m%Y%H%M%S")
datef = datetime.now().strftime("%d-%m-%y %H:%M:%S")
print(datef)
Try other methods by searching on the site. That is if this doesn’t work