#include<stdio.h>  
  
int main()  
{  
    int num , i, prime = 0; 
    printf("Enter a number\n");  
    scanf("%d", &num); 
    for(i = 2; i < num; i++)  
    {  
        if(num % i == 0)  
        {  
            prime = 0;  
            break;  
        }  
    }  
  
    if(prime)  
        printf("%d is a Prime Number\n", num);  
    else  
        printf("%d is a not Prime Number\n", num);  
  
    return 0;  
}  

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: