OFFSET
1,1
COMMENTS
See link for statement of the problem.
LINKS
Alois P. Heinz, Table of n, a(n) for n = 1..10000
Popular Computing (Calabasas, CA), Problems 195 and 196, Vol. 5 (No. 55, 1977), annotated and scanned copy of page PC55-4. See Problem 196.
MATHEMATICA
A256964 = {}; nlist = Range[3, 2 10^4 + 10]; Do[x = nlist[[i]]; AppendTo[ A256964, nlist[[x+i]]]; nlist[[x+i]] = x, {i, 10^4}]; A256964 (* Jean-François Alcover, May 31 2019, after Chai Wah Wu *)
PROG
(Python)
A256964_list, nlist = [], list(range(3, 2*10**4+10))
for i in range(10**4):
x = nlist[i]
A256964_list.append(nlist[x+i])
nlist[x+i] = x # Chai Wah Wu, Apr 16 2015
CROSSREFS
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Apr 16 2015
STATUS
approved