Semi primes | Sololearn: Learn to code for FREE!
0

Semi primes

how to check if an integer can be expressed as a sum of two semi primes in c language?(examples: 30=15+15 and 45=35+10 as we see in this example 35,10,15 are semi prime) (A semi prime number is an integer which can be expressed as a product of two distinct primes. examples: 15=3*5)

14th Oct 2018, 2:39 PM
SAMBHAV KUMAR THAKUR
SAMBHAV KUMAR THAKUR - avatar
2 ответов
+ 4
bool isPrime(int n){...} bool isSemiPrime(int n){...} bool isSumOfSemiPrime(int n){...}
14th Oct 2018, 4:49 PM
Flandre Scarlet
Flandre Scarlet - avatar
0
#scarlet I want logic/code for this only in c language.....so pls...
14th Oct 2018, 6:06 PM
SAMBHAV KUMAR THAKUR
SAMBHAV KUMAR THAKUR - avatar