login
Squares that contain multi-digit prime substrings.
1

%I #5 Feb 28 2013 08:57:31

%S 196,289,361,441,529,676,729,841,961,1024,1089,1156,1296,1369,1521,

%T 1764,1936,2025,2116,2304,2401,2601,2809,2916,3025,3136,3721,4096,

%U 4356,4489,4761,5041,5329,5476,5776,5929,6241,6561,6724,6889,7056,7396,7569,7921

%N Squares that contain multi-digit prime substrings.

%H Harvey P. Dale, <a href="/A119667/b119667.txt">Table of n, a(n) for n = 0..1000</a>

%e 196 contains 19 - a prime number as a substring. 289 contains 89 - a prime number as a substring.

%t mdpsQ[n_]:=Module[{idn=IntegerDigits[n]},Or@@PrimeQ[Flatten[ Table[ FromDigits/@ Partition[idn,i,1],{i,2,Length[idn]-1}]]]]; Select[ Range[ 100]^2,mdpsQ] (* _Harvey P. Dale_, Feb 28 2013 *)

%K base,nonn

%O 0,1

%A _Tanya Khovanova_, Jul 29 2006

%E More terms from _Joshua Zucker_, Aug 04 2006