#include< stdio.h >
#include< conio.h >
void main()
{
int num;
clrscr();
printf("Enter a number:");
scanf("%d",&num);
if(num%10==0)
{
printf("The number is divisible by 10");
}
else
{
printf("The number is not divisible by 10");
}
getch();
}
OUTPUT :
Enter a number :60
The number is divisible by 10
OR
OUTPUT :
Enter a number :65
The number is not divisible by 10
#include< conio.h >
void main()
{
int num;
clrscr();
printf("Enter a number:");
scanf("%d",&num);
if(num%10==0)
{
printf("The number is divisible by 10");
}
else
{
printf("The number is not divisible by 10");
}
getch();
}
OUTPUT :
Enter a number :60
The number is divisible by 10
OR
OUTPUT :
Enter a number :65
The number is not divisible by 10
No comments :
Post a Comment