login
Numbers n such that string 5,2 occurs in the base 8 representation of n but not of n+1.
0

%I #7 Nov 03 2016 13:49:07

%S 42,106,170,234,298,343,362,426,490,554,618,682,746,810,855,874,938,

%T 1002,1066,1130,1194,1258,1322,1367,1386,1450,1514,1578,1642,1706,

%U 1770,1834,1879,1898,1962,2026,2090,2154,2218,2282,2346

%N Numbers n such that string 5,2 occurs in the base 8 representation of n but not of n+1.

%t SequencePosition[Table[If[SequenceCount[IntegerDigits[n,8],{5,2}]>0,1,0],{n,2500}],{1,0}][[All,1]] (* Requires Mathematica version 10 or later *) (* _Harvey P. Dale_, Nov 03 2016 *)

%K nonn,base

%O 1,1

%A _Clark Kimberling_