ramylan00
ramylan00 ramylan00
  • 12-12-2020
  • Computers and Technology
contestada

write c++ program from 1to 100 to find prime numbers using statement.

please help me​

write c program from 1to 100 to find prime numbers using statementplease help me class=

Respuesta :

th3g3ntl3man
th3g3ntl3man th3g3ntl3man
  • 19-12-2020

Answer:

int count;

for (int i = 1; i <= 100; i++){

count = 0;

for (int j = 1; j <=i; j++)

if (i%j==0) count ++;

if (count == 2) cout << i << " ";

}

Answer Link

Otras preguntas

one number is 6 less than another, their sum is 22
what do the narragansett do every August
why cant we find treasure
re write this in the present tense tom baked a cake
The energy needed to get a reaction started is the a. enzyme energy. b. activation energy. c. catalyst energy. d. chemical energy.
what is the name for different forms of a gene
re write this in the present tense tom baked a cake
Your heart functions in your body as a(n) A. series of joints responsible for endurance. B. muscle that helps to pump oxygen around the body. C. organ for ab
A situation in which a gene has more than two alleles is known as a. incomplete dominance. b. codominance. c. polygenic dominance. d. multiple alleles
18% of what number is 43?