cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A257485 Numbers n such that the decimal expansions of both n and n^2 have 2 as smallest digit and 9 as largest digit.

Original entry on oeis.org

927, 962, 982, 2293, 2393, 2593, 2693, 2792, 2923, 2927, 2932, 2937, 2964, 2973, 2977, 2982, 2983, 4792, 4923, 4927, 5692, 6292, 6923, 6925, 6927, 7923, 7924, 7927, 8792, 8925, 9232, 9233, 9267, 9268, 9273, 9286, 9287, 9288, 9325, 9326, 9327, 9342, 9423, 9427
Offset: 1

Views

Author

Felix Fröhlich, Apr 26 2015

Keywords

Crossrefs

Programs

  • Mathematica
    fQ[n_] := Block[{d = DigitCount@ n}, Plus @@ Join[First@ d, Last@ d] == 0 && d[[2]] > 0 && d[[9]] > 0]; Select[Range@ 10000, fQ@ # && fQ[#^2] &] (* Michael De Vlieger, Apr 27 2015 *)
    s2l9Q[n_]:=Max[IntegerDigits[n]]==9&&Min[IntegerDigits[n]]==2; Select[ Range[ 10000],AllTrue[{#,#^2},s2l9Q]&] (* Harvey P. Dale, Dec 06 2018 *)
  • PARI
    is(n) = vecmin(digits(n))==2 && vecmin(digits(n^2))==2 && vecmax(digits(n))==9 && vecmax(digits(n^2))==9