Write a program in c find the number is even or odd - CodeTextPro | Free Web Tutorial

Codetextpro Provides free Web tutorial, HTML, CSS, C, C++, Java, JavaScript, PHP, MySql, Python, Program, Programming Notes, Programming Questions and more.

Programming

Friday, January 4, 2019

Write a program in c find the number is even or odd

Find the number is Even or Odd

#include<stdio.h>
#include<conio.h>
main()
{
int a;
printf("Enter The Number: ");
scanf("%d",&a);
if(a%2==0)
{
printf("a is even");
}
else
{
printf("a is odd");
}
getch();
}


Output:





No comments:

Post a Comment