#include<stdio.h> 

int main()
{

    int n,i;

    printf("Enter a Number:\n");
    scanf("%d",&n);

    for(i=2; i<=n/2; i++)
    {
        if(n%i==0) {
            break;
        }
    }

    if(i> n/2)
    {
        printf("Prime");
    }
    else {
        printf("Not Prime");
    }

    return 0;
}
     
           
Note: Need to be arranged in compiler after copied
   

 OutPut:

Enter a Number: 7 7 is a Prime number