OFFSET
1,2
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 1..375
FORMULA
EXAMPLE
a(4) = 619 = 4321 mod 1234.
MAPLE
a:= n-> irem(parse(cat(n-i$i=0..n-1)), parse(cat(i$i=1..n))):
seq(a(n), n=1..20); # Alois P. Heinz, Nov 19 2018
MATHEMATICA
r = f = ""; Do[r = ToString[n] <> r; f = f <> ToString[n]; Print[Mod[ToExpression[r], ToExpression[f]]], {n, 1, 30}] (* Ryan Propper, Aug 26 2005 *)
nn=30; Module[{r, f}, Table[f=Flatten[IntegerDigits/@Range[n]]; r=Flatten[ IntegerDigits/@Range[n, 1, -1]]; Mod[FromDigits[r], FromDigits[f]], {n, nn}]] (* Harvey P. Dale, Mar 04 2013 *)
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Amarnath Murthy, Jun 17 2004
EXTENSIONS
Corrected and extended by Ryan Propper, Aug 26 2005
STATUS
approved