cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A032740 Numbers k such that k is a substring of 2^k.

This page as a plain text file.
%I A032740 #31 Feb 02 2025 15:30:12
%S A032740 6,10,35,36,37,44,49,51,60,67,72,73,82,85,89,93,179,188,190,191,226,
%T A032740 234,252,297,312,321,356,373,391,425,429,430,438,445,451,475,478,479,
%U A032740 486,516,519,521,526,549,551,581,582,583,598,601,603,609,613,619,627,632,642,652,653,655,660
%N A032740 Numbers k such that k is a substring of 2^k.
%H A032740 David W. Wilson, <a href="/A032740/b032740.txt">Table of n, a(n) for n = 1..10000</a>
%e A032740 2^93 = 99035203142830421991929_93_792.
%t A032740 d[n_] := IntegerDigits[n]; parQ[n_] := MemberQ[Partition[d[2^n], Length[x = d[n]], 1], x]; Select[Range[660], parQ] (* _Jayanta Basu_, Jun 17 2013 *)
%t A032740 Select[Range[700],SequenceCount[IntegerDigits[2^#],IntegerDigits[#]]>0&] (* Requires Mathematica version 10 or later *) (* _Harvey P. Dale_, Jul 10 2019 *)
%o A032740 (Haskell)
%o A032740 import Data.List (isInfixOf)
%o A032740 a032740 n = a032740_list !! (n-1)
%o A032740 a032740_list = [x | x <- [0..], show x `isInfixOf` (show $ 2 ^ x)]
%o A032740 -- _Reinhard Zumkeller_, Jan 19 2014
%Y A032740 Cf. A049301, A049302, A049303, A049304, A049305, A049306, A049307.
%K A032740 base,nonn,nice,easy
%O A032740 1,1
%A A032740 _Patrick De Geest_, May 15 1998