C Program to test whether the given number is even or odd number
#include<stdio.h>
int main()
{
int n,r;
printf("Enter any number");
scanf("%d",&n);
r=n%2;
if (r==0)
printf("%d is even number",n);
else
printf("%d is odd number",n);
return 0;
}
C Program to test whether the given number is divisible by 7 or not
#include<stdio.h>
int main()
{
int n,r;
printf("Enter any number");
scanf("%d",&n);
r=n%7;
if (r==0)
printf("%d is divisible by 7",n);
else
printf("%d is not divisible by 7",n);
return 0;
}