%I #54 Oct 29 2024 14:41:08
%S 0,1,10,11,20,21,30,31,40,41,50,51,60,61,70,71,80,81,90,91,100,101,
%T 110,111,120,121,130,131,140,141,150,151,160,161,170,171,180,181,190,
%U 191,200,201,210,211,220,221,230,231,240,241,250,251,260,261,270,271
%N Numbers that are congruent to 0 or 1 mod 10.
%C From _Wesley Ivan Hurt_, Sep 26 2015: (Start)
%C Numbers with last digit 0 or 1.
%C Complement of (A260181 Union A262389). (End)
%C Numbers k such that floor(k/2) = 5*floor(k/10). - _Bruno Berselli_, Oct 05 2017
%H Vincenzo Librandi, <a href="/A197652/b197652.txt">Table of n, a(n) for n = 1..1000</a>
%H <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (1,1,-1).
%F a(n) = Sum_{k>=0} A030308(n,k)*b(k) with b(0)=1 and b(k) = 5*2^k = A020714(k) for k>0.
%F From _Zak Seidov_, Oct 20 2011: (Start)
%F a(n) = a(n-2) + 10.
%F a(n) = 5*n - 7 - 2*(-1)^n. (End)
%F From _Vincenzo Librandi_, Jul 11 2012: (Start)
%F G.f.: x^2*(1+9*x)/((1+x)*(1-x)^2).
%F a(n) = a(n-1) + a(n-2) - a(n-3) for n>3. (End)
%F E.g.f.: 9 + (5*x - 7)*exp(x) - 2*exp(-x). - _David Lovler_, Sep 03 2022
%p A197652:=n->5*n-7-2*(-1)^n: seq(A197652(n), n=1..100); # _Wesley Ivan Hurt_, Sep 26 2015
%t CoefficientList[Series[x*(1+9*x)/((1+x)*(1-x)^2),{x,0,50}],x] (* _Vincenzo Librandi_, Jul 11 2012 *)
%o (PARI) a(n)=n\2*10+n%2*9-9 \\ _Charles R Greathouse IV_, Oct 25 2011
%o (Magma) [5*n-7-2*(-1)^n: n in [1..60]]; // _Vincenzo Librandi_, Jul 11 2012
%o (Python)
%o def A197652(n): return 5*n-(5 if n&1 else 9) # _Chai Wah Wu_, Oct 29 2024
%Y Cf. A020714, A030308, A260181, A262389.
%K nonn,easy,changed
%O 1,3
%A _Philippe Deléham_, Oct 16 2011