In 1939 Juzuk described a way to generate the fourth powers of natural numbers. Group the natural numbers like this:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 ...
Scratch each second group:
1 4 5 6 11 12 13 14 15 ...
The sum of the n remaining groups is n**4.
- Input: none
- Task: print the fourth powers upto 100**4, using Juzuk's method.
Output:
0 (optional) 1 16 81 ... 100000000
n-1
result in account when computing forn
? Is it allowed to simplify integer sums using then(n+1)/2
formula? When is it no longer Juzuk’s method? \$\endgroup\$