Wednesday 30 January 2013

WAP TO FIND OUT EVEN OR ODD NUMBER (IF-ELSE)


void main ()
{
int a;
clrscr ();
printf ("Enter the value of A: ");
scanf("%d",&a);
if (a%2==0)
{
printf ("\nNumber is Even");
}
else
{
printf("\nNumber is Odd");
}
getch ();
}

No comments:

Post a Comment

Comment