%I #53 Apr 05 2023 09:40:36
%S 0,1,0,3,0,1,0,7,0,1,0,3,0,1,0,15,0,1,0,3,0,1,0,7,0,1,0,3,0,1,0,31,0,
%T 1,0,3,0,1,0,7,0,1,0,3,0,1,0,15,0,1,0,3,0,1,0,7,0,1,0,3,0,1,0,63,0,1,
%U 0,3,0,1,0,7,0,1,0,3,0,1,0,15,0,1,0,3,0,1,0,7,0,1,0,3,0,1,0,31,0,1,0,3,0,1,0
%N a(n) = 2^A007814(n+1) - 1.
%C This is Guy Steele's sequence GS(1, 6) (see A135416).
%H Antti Karttunen, <a href="/A135481/b135481.txt">Table of n, a(n) for n = 0..16384</a>
%F a(n) = A006519(n+1) - 1. - _R. J. Mathar_, Feb 10 2016
%p GS(1,6,200); # see A135416
%t Table[BitAnd[i, BitNot[i+1]], {i, 0, 200}] (* _Peter Luschny_, Jun 01 2011 *)
%o (PARI) a(n) = 2^valuation(n+1, 2)-1; \\ _Michel Marcus_, Nov 19 2017
%o (PARI) a(n) = bitand(bitneg(n+1), n); \\ _Ruud H.G. van Tol_, Apr 05 2023
%o (Julia)
%o using IntegerSequences
%o A135481List(len) = [Bits("CNIMP", n+1, n) for n in 0:len]
%o println(A135481List(100)) # _Peter Luschny_, Sep 25 2021
%o (Python)
%o def A135481(n): return ~(n+1)&n # _Chai Wah Wu_, Jul 06 2022
%Y Cf. A006519, A007814, A135416, A140670, A136013 (partial sums).
%K nonn,easy
%O 0,4
%A _N. J. A. Sloane_, based on a message from Guy Steele and _Don Knuth_, Mar 01 2008
%E a(0) = 0 prepended by _Andrey Zabolotskiy_, Oct 08 2019, based on _Lothar Esser_'s contribution