Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import datetime
- months = {
- 1 : "jan",
- 2 : "feb",
- 3 : "mar",
- 4 : "apr",
- 5 : "may",
- 6 : "jun",
- 7 : "jul",
- 8 : "aug",
- 9 : "sep",
- 10 : "oct",
- 11 : "nov",
- 12 : "dec"
- }
- now = datetime.datetime.now()
- day = "0" + str(now.day) if len(str(now.day)) == 1 else str(now.day)
- year = "0" + str(now.year) if len(str(now.year)) == 1 else str(now.year)
- DATE = day + months[now.month] + year
- print DATE
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement