We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
I was also not looping correctly to January or more precisely, I counted by error the sunday on the 1st of the month also in 13th non-existent month. So in particular loop from 31.12. 2292 to 1.1. 2293 returned 2 Sundays. Thanks for the tip, after the fix, it worked well :)
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Project Euler #19: Counting Sundays
You are viewing a single comment's thread. Return to all comments →
I was also not looping correctly to January or more precisely, I counted by error the sunday on the 1st of the month also in 13th non-existent month. So in particular loop from 31.12. 2292 to 1.1. 2293 returned 2 Sundays. Thanks for the tip, after the fix, it worked well :)