Deceptive numbers: Difference between revisions

Content deleted Content added
Added Algol 68
Line 44:
<lang algol68>BEGIN # find repunits (all digits are 1 ) such that R(n-1) is divisible by n and n is not prime #
# R(n) is the nth repunit, so has n 1s #
PR precision 8000 PR # set precision of LONG LONG INT, enough for upto R(8000) #
PR read "primes.incl.a68" PR # include prime utilities #
[]BOOL prime = PRIMESIEVE 8000;
LONG LONG INT repunit := 0;