p
y
c
h
a
l
l
e
n
g
e
r
Home
Intermediate Python
Datetime
Datetime
datetime
date
timedelta
strftime
strptime
now
today
date arithmetic
NEXT
Dates and datetimes
LESSON
Exercise: Create a date
CHALLENGE
Exercise: Create a datetime with a time
CHALLENGE
Exercise: Read attributes from a date
CHALLENGE
Exercise: Get the current moment
CHALLENGE
Exercise: Find the weekday
CHALLENGE
Formatting and parsing dates
LESSON
Exercise: Format a date as YYYY-MM-DD
CHALLENGE
Exercise: Format with month name
CHALLENGE
Exercise: Parse a date string
CHALLENGE
Exercise: Parse a custom format
CHALLENGE
Exercise: Reformat a date string
CHALLENGE
Date arithmetic with timedelta
LESSON
Exercise: Build a timedelta
CHALLENGE
Exercise: Add days to a date
CHALLENGE
Exercise: Subtract two dates
CHALLENGE
Exercise: Days between two dates
CHALLENGE
Exercise: Add hours to a datetime
CHALLENGE