last 2 and 3 digits of fibonacci repeats each 1500 terms
last 4 digits repeats each 15,000
last 5 digits repeats each 150,000
last 6 digits repeats each 1,500,000
last 7 digits repeats each 15,000,000
Nice idea about finding "the loop length" after which "endings" repeat :) Perhaps some other puzzle could be invented from it.
However my approach was simpler - just taking modulo by 10eX where X is amount of digits in the number we seek. Then numbers won't grow longer than this.
I suspect your and mine approaches are really two versions of the same fact, however
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
There a trick you can use:
last 2 and 3 digits of fibonacci repeats each 1500 terms
last 4 digits repeats each 15,000
last 5 digits repeats each 150,000
last 6 digits repeats each 1,500,000
last 7 digits repeats each 15,000,000
x = 92.740
y = 4.562.603
z = 280.555.264
Nice idea about finding "the loop length" after which "endings" repeat :) Perhaps some other puzzle could be invented from it.
However my approach was simpler - just taking modulo by
10eX
whereX
is amount of digits in the number we seek. Then numbers won't grow longer than this.I suspect your and mine approaches are really two versions of the same fact, however