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.

A243355 Numbers n such that n and prime(n) have no common digits.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 8, 9, 10, 12, 15, 16, 17, 19, 20, 21, 22, 24, 25, 26, 27, 28, 35, 36, 39, 40, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 53, 57, 58, 59, 60, 61, 64, 65, 66, 67, 68, 69, 70, 71, 72, 76, 77, 79, 85, 86, 87, 88, 89, 90, 91, 93, 96, 98, 99, 101
Offset: 1

Views

Author

Colin Barker, Jun 03 2014

Keywords

Examples

			98 is in the sequence because prime(98) = 521, which has no digits in common with 98.
		

Crossrefs

Cf. A000040, A074350, A119393 (complement).

Programs

  • Haskell
    import Data.List (intersect)
    a243355 n = a243355_list !! (n-1)
    a243355_list = filter
       (\x -> null $ show x `intersect` (show $ a000040 x)) [1..]
    -- Reinhard Zumkeller, Sep 14 2014
  • Mathematica
    Select[Range[110],Intersection[IntegerDigits[#],IntegerDigits[Prime[#]]]=={}&] (* Harvey P. Dale, Aug 11 2023 *)
  • PARI
    s=[]; for(n=1, 300, if(setintersect(vecsort(digits(n),,8), vecsort(digits(prime(n)),,8))==[], s=concat(s, n))); s