Computer Science, asked by GargiShukla, 1 year ago

write a program in c++ to print the prime numbers between 100 to 200

Answers

Answered by soumendu
3

#include <stdio.h>

void main()

{

int i, j;

   for(int i=100;i<=200;i++)

   {

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

       {

           if(i%j==0)

               break;

           else if(i==j+1)

               printf("%d\n",i);

       }

   }

}


GargiShukla: thanks a lot
Similar questions