Session Ready
Exercise

Localizing time with pendulum

Here, you're going to use pendulum to practice doing some common datetime operations!

Instructions
100 XP
  • Import the pendulum module.
  • Create a now datetime for Tokyo ('Asia/Tokyo') called tokyo_dt.
  • Convert tokyo_dt to Los Angeles time ('America/Los_Angeles'). Store the result as la_dt.
  • Print the ISO 8601 string of la_dt, using the .to_iso8601_string() method.