Sunday, April 17, 2011

program for odd even

/****************************
* Umang B Bhatt *
* bhatt.umang7@gmail.com *
*****************************/

/**
* program for odd even no / number
*/


#include<stdio.h>
int main(int argc, char *argv[])
{


int
no;

printf("Enter a no to know whether a number is odd or even: ");
scanf("%d",&no);

if
(no%2==0)
{

printf("the entered number %d is even\n",no);
}


else

{

printf("the entered number %d is odd\n",no);
}

//getch();
return 0;
}