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.

A141642 Composite numbers whose sum of digits is a prime.

This page as a plain text file.
%I A141642 #16 Dec 14 2021 12:12:47
%S A141642 12,14,16,20,21,25,30,32,34,38,49,50,52,56,58,65,70,74,76,85,92,94,98,
%T A141642 102,104,106,110,111,115,119,120,122,124,128,133,140,142,146,148,155,
%U A141642 160,164,166,175,182,184,188,200,201,203,205,209,210,212,214,218,221,230,232,236
%N A141642 Composite numbers whose sum of digits is a prime.
%H A141642 Harvey P. Dale, <a href="/A141642/b141642.txt">Table of n, a(n) for n = 1..1000</a>
%t A141642 Select[Range[300],CompositeQ[#]&&PrimeQ[Total[IntegerDigits[#]]]&] (* _Harvey P. Dale_, Feb 19 2018 *)
%o A141642 (Python)
%o A141642 from sympy import isprime
%o A141642 def ok(n): return isprime(sum(map(int, str(n)))) and not isprime(n)
%o A141642 print([k for k in range(237) if ok(k)]) # _Michael S. Branicky_, Dec 14 2021
%Y A141642 Cf. A046704, A163622, A228019.
%K A141642 nonn,base
%O A141642 1,1
%A A141642 _Juri-Stepan Gerasimov_, Sep 03 2008
%E A141642 More terms from _N. J. A. Sloane_, Sep 03 2008