Joined September 2020
·

ksbg

Nice approach!
How would you support a finite sliding window as well?

BTW, i think you got a bug when you check the negative curr, i think it should be:
if (curr < 0) { curr = num + (curr % num); }

Achievements
1 Karma
0 Total ProTip Views