OFFSET
1,1
FORMULA
a(6*k-3) = 6*(k-1)-4, a(6*k-2) = 6*(k-2)-2, a(6*k-1) = 6, a(6*k) = 6*(k-1)-1, a(6*k+1) = 6*k-2, a(6*k+2) = 15 for k > 4.
MAPLE
f:= proc(n) option remember; procname(n-procname(n-2))+procname(n-procname(n-4)) end proc:
for i from 1 to 10 do f(i):= 11-i od:
map(f, [$1..100]); # Robert Israel, May 16 2018
PROG
(PARI) q=vector(10^5); for(n=1, 10, q[n]=10-n+1); for(n=11, #q, q[n]=q[n-q[n-2]]+ q[n-q[n-4]]); q
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Altug Alkan, May 15 2018
STATUS
approved