%I #27 May 18 2015 09:59:24
%S 5793,5963,6593,6963,7593,8593,9357,9463,9663,9883,9934,9937,9938,
%T 57937,58893,58937,58963,59463,59537,59543,59663,59736,59833,59863,
%U 59883,65937,66893,68963,69537,69634,69883,73956,73957,79583,79836,79837,79934,83594,85938
%N Numbers n such that the decimal expansions of both n and n^2 have 3 as the digit with the smallest value and 9 as the digit with the largest value.
%H Felix Fröhlich, <a href="/A238553/b238553.txt">Table of n, a(n) for n = 1..10000</a>
%e 5793 is in the sequence because its smallest digit is 3 and its largest digit is 9, and this is also true of 5793^2 = 33558849.
%e 5833 is not in the sequence because 5833^2 = 34023889, which contains a 0 and a 2.
%t fQ[n_] := Block[{c = DigitCount@ n}, And[Plus @@ Take[c, {1, 2}] == 0, Last@ c == 0, c[[3]] > 0, c[[9]] > 0]]; Select[Range@ 90000, fQ@ # && fQ[#^2] &] (* _Michael De Vlieger_, May 05 2015 *)
%o (PARI) is(n) = vecmin(digits(n))==3 && vecmin(digits(n^2))==3 && vecmax(digits(n))==9 && vecmax(digits(n^2))==9
%Y Cf. A256630, A256631, A256633, A256634, A256708, A256709, A256889, A257197, A257210, A257211, A256601, A257310, A249915, A257123, A257368, A257485, A257486, A257498, A257534, A254071, A254072, A254074.
%K nonn,base
%O 1,1
%A _Felix Fröhlich_, Apr 27 2015