avatar Bite 328. Longest coding streak

What is your longest streak of completed Bites?

In Bite 139, you learned how to calculate your current coding streak. In this Bite, you are doing data analysis to calculate the longest coding streak of completed Bites you have ever had while using PyBites.

If you have explored your PyBites settings, you may have noticed a section on Data Exports, Progress Reset and Privacy. In that section, you can download all your PyBites data in a JSON file!

For this Bite, we have cut down the JSON file. You will need to focus on the the commits.

"commits": [
          "bite": "Bite 90. What South Park characters talk most?",
          "code": "print('hello world')",
          "date": "2019-10-14 22:26:23.122569+00:00",
          "passed": false

You will need to find all the passed commits, retrieve the associated datetimes and determine the longest streak within the dataset. We are trying to capture our longest daily streak of completed Bites (Bites that pass all tests *1).

See the docstrings for more details.

I hope this Bite gives you the confidence to download and analyze datasets from other services and see what insights you can can learn about yourself.

*1) As opposed to the platform in this Bite, a streak is defined as the number of days where you completed at least one Bite.

Login and get coding
go back Advanced level
Bitecoin 4X

22 out of 24 users completed this Bite.
Will you be the 23rd person to crack this Bite?
Resolution time: ~100 min. (avg. submissions of 5-240 min.)
Our community rates this Bite 7.0 on a 1-10 difficulty scale.
» Up for a challenge? 💪

Focus on this Bite hiding sidebars, turn on Focus Mode.

Ask for Help