login
A178314
Numbers n with property that n^2 contains "123" as a substring.
5
106, 111, 351, 352, 844, 1060, 1110, 1111, 1112, 1113, 1677, 2394, 2452, 2606, 2669, 3352, 3508, 3509, 3510, 3511, 3512, 3513, 3514, 3515, 3516, 3517, 3518, 3519, 3520, 3521, 4138, 4373, 4518, 4573, 4596, 4608, 4713, 4894, 5106, 5208, 5589, 5934, 6566
OFFSET
1,1
COMMENTS
Corresponding squares: 1_123_6, 123_21, 123_201, 123_904, 7_123_36, 1_123_600, 123_2100, 123_4321,123_6544, 123_8769, 28_123_29, 573_123_6.
LINKS
MATHEMATICA
s={}; Do[If[ !StringFreeQ[ToString[k^2], "123"], AppendTo[s, k]; Print[k]], {k, 0, 10000}]
Select[Range[7000], SequenceCount[IntegerDigits[#^2], {1, 2, 3}]>0&] (* The program uses the SequenceCount function from Mathematica version 10 *) (* Harvey P. Dale, Nov 02 2015 *)
CROSSREFS
Sequence in context: A104315 A338602 A181739 * A010339 A277605 A102804
KEYWORD
base,nonn
AUTHOR
Zak Seidov, May 24 2010
STATUS
approved