Find whether number is even or odd - C - A5P6
in
SPNM
- on
6:27 PM
-
No comments
/* Write a program to find whether number is even or odd */
#include<stdio.h>
#include<conio.h>
void check(int);
void main()
{
int no;
clrscr();
printf("Enter Number->");
scanf("%d",&no);
check(no);
getch();
}
void check(int no)
{
if(no%2!=0)
printf("\nIt is an ODD Number");
else
printf("\nIt is an EVEN Number");
}
Post a Comment