Header Ads Widget

C program to check that given number is even or odd

Here in this post we will write a program for finding the even and odd element . So first we have to know that what is even element . The number which is divisible by 2 is called even number otherwise known as odd element . C program to check that a number is even or not given below.

C-program to check a number is even or not:-
#include<stdio.h>
int main()
{
int n;
printf("Enter any number: ");
scanf("%d",&n);
if(n%2==0)
printf("Number %d is even",n);
else
printf("Number %d is odd",n);
return 0;
}



Output:-

Enter any number: 5
Number 5 is odd





keyword:- 

 ,write a program to check whether the given number is even or odd,

,even odd program in c using function,

,write a program to check whether the given number is even or odd in python,

,write a program to check whether the given number is even or odd in c,

,write a c program to check whether a given number is positive or negative,

,odd number program in c,

,write a program to find whether the given number is even or odd using if else statement,

,write a program to check whether the given number is even or odd in java,

,even odd program in c using function,

,odd number program in c,

,write a program to find whether the given number is even or odd using if else statement,

,write a program to check whether the given number is even or odd in java,

,write a program to check whether the given number is even or odd,

,write a program to check whether the given number is even or odd in python,

Recommended Post:

Full C course:-    

Key points:-

Cracking the coding interview:-

 Array and string:-

Tree and graph:-

Hackerearth Problems:-

Hackerrank Problems:-

Data structure:-

 MCQs:-

Post a Comment

0 Comments