login
Nonprimes that contain digits 0 and 1 only.
2

%I #5 Dec 26 2015 15:20:22

%S 1,10,100,110,111,1000,1001,1010,1011,1100,1101,1110,1111,10000,10001,

%T 10010,10011,10100,10101,10110,11000,11001,11010,11011,11100,11101,

%U 11110,11111,100000,100001,100010,100011,100100,100101,100110,100111

%N Nonprimes that contain digits 0 and 1 only.

%C a(n) = binary expansion of numbers A174416(n) (i.e. numbers whose binary expansion is a decimal nonprime).

%H Harvey P. Dale, <a href="/A174417/b174417.txt">Table of n, a(n) for n = 1..1000</a>

%t Select[Sort[Flatten[Table[FromDigits/@(Join[{1},#]&/@Tuples[{1,0},n]),{n,0,5}]]],!PrimeQ[#]&] (* _Harvey P. Dale_, Dec 26 2015 *)

%K nonn,base

%O 1,2

%A _Jaroslav Krizek_, Mar 19 2010

%E Keyword base added by _Reinhard Zumkeller_, Mar 31 2010