Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A117737
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A117737 Numbers such that the (positive) difference between the sum of the digits and the product of the digits is a primenumber. +0
1
20, 24, 25, 27, 29, 30, 33, 34, 35, 37, 38, 42, 43, 45, 47, 49, 50, 52, 53, 54, 56, 57, 59, 65, 67, 70, 72, 73, 74, 75, 76, 78, 79, 83, 87, 92, 94, 95, 97, 101, 102, 104, 106, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 125, 126, 128, 131, 133, 140 (list; graph; listen)
OFFSET

1,1

EXAMPLE

97 is in the sequence because (1)the sum of its digits is 16,(2)the product of its digits is 63 and the difference between 16 and 63 is 47, which is a prime.

PROGRAM

(PARI) sudig(i, suOrmul)= { local(nshft, resul) ; nshft = i ; resul = nshft % 10 ; nshft = nshft \ 10 ; while(nshft>0, if(suOrmul==0, resul += nshft % 10, resul *= nshft % 10 ) ; nshft \= 10 ; ) ; return(resul) ; } { for(n=10, 150, summ = sudig(n, 0) ; mull = sudig(n, 1) ; if( isprime(summ-mull), print1(n, ", ") ) ; ) ; } - R. J. Mathar (mathar(AT)strw.leidenuniv.nl), Apr 21 2006

CROSSREFS

Cf. A000040.

Adjacent sequences: A117734 A117735 A117736 this_sequence A117738 A117739 A117740

Sequence in context: A013339 A031169 A093716 this_sequence A062908 A111323 A114843

KEYWORD

base,nonn

AUTHOR

Luc Stevens (lms022(AT)yahoo.com), Apr 14 2006

EXTENSIONS

More terms from R. J. Mathar (mathar(AT)strw.leidenuniv.nl), Apr 21 2006

page 1

Search completed in 0.002 seconds

Lookup | Welcome | Find friends | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
More pages | Superseeker | Maintained by N. J. A. Sloane (njas@research.att.com)

Last modified November 8 20:39 EST 2009. Contains 166234 sequences.


AT&T Labs Research