1. सीखें
  2. /
  3. पाठ्यक्रम
  4. /
  5. Working with Dates and Times in Python

Connected

अभ्यास

How long per weekday?

Pandas has a number of datetime-related attributes within the .dt accessor. Many of them are ones you've encountered before, like .dt.month. Others are convenient and save time compared to standard Python, like .dt.day_name().

निर्देश

100 XP
  • Add a new column to rides called 'Ride start weekday', which is the weekday of the Start date.
  • Print the median ride duration for each weekday.