[go: up one dir, main page]

login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A257368
Numbers n such that the decimal expansions of both n and n^2 have 2 as smallest digit and 8 as largest digit.
10
278, 528, 582, 826, 2385, 2585, 2868, 2872, 2875, 2878, 2885, 4782, 4832, 4872, 5278, 5328, 6872, 7238, 7258, 7268, 7582, 8232, 8266, 8275, 8278, 8284, 8522, 8524, 8528, 8628, 8732, 8822, 23385, 23628, 23782, 23826, 25582, 25668, 25785, 25856, 26238, 26878
OFFSET
1,1
LINKS
MATHEMATICA
fQ[n_] := Block[{d = DigitCount@ n}, Plus @@ Prepend[Take[d, -2], First@ d] == 0 && d[[2]] > 0 && d[[8]] > 0]; Select[Range@ 27000, fQ@ # && fQ[#^2] &] (* Michael De Vlieger, Apr 27 2015 *)
PROG
(PARI) is(n) = vecmin(digits(n))==2 && vecmin(digits(n^2))==2 && vecmax(digits(n))==8 && vecmax(digits(n^2))==8
KEYWORD
nonn,base
AUTHOR
Felix Fröhlich, Apr 25 2015
STATUS
approved