%I #29 Nov 03 2023 20:22:06
%S 0,1,1,2,3,5,8,31,93,421,415,638,3501,9314,51821,53116,739401,715297,
%T 8964541,8389769,1345371,415379,570671,50689,63126,518311,734185,
%U 6942521,6076767,88291031,89776349,83760871,22735371,242694601,279924562,361916225,787048146
%N Iccanobif numbers: add previous two terms and reverse the sum.
%H Alois P. Heinz, <a href="/A014258/b014258.txt">Table of n, a(n) for n = 0..1000</a> (first 200 terms from N. J. A. Sloane)
%H N. J. A. Sloane, <a href="/transforms.txt">Transforms</a>.
%p with(transforms); f:=proc(n) option remember; if n <= 1 then n else digrev(f(n-1)+f(n-2)); fi; end; [seq(f(n),n=0..50)];
%t Clear[ BiF ]; BiF[ 0 ]=0; BiF[ 1 ]=1; BiF[ n_Integer ] := BiF[ n ]=Plus@@(IntegerDigits[ BiF[ n-2 ]+BiF[ n-1 ], 10 ]//(#*Array[ 10^#&, Length[ # ], 0 ])&); Array[ BiF, 40, 0 ]
%t nxt[{a_,b_}]:={b,FromDigits[Reverse[IntegerDigits[a+b]]]}; Transpose[ NestList[ nxt,{0,1},40]][[1]] (* _Harvey P. Dale_, Jun 15 2013 *)
%o (Python)
%o from itertools import islice
%o def A014258_gen(): # generator of terms
%o a, b = 0, 1
%o yield 0
%o while True:
%o yield b
%o a, b = b, int(str(a+b)[::-1])
%o A014358_list = list(islice(A014258_gen(),20)) # _Chai Wah Wu_, Jan 15 2022
%Y Cf. A000045, A001129, A014259, A014260.
%K nonn,base,easy
%O 0,4
%A _N. J. A. Sloane_
|