C# Corner
Tech
News
Videos
Forums
Jobs
Books
Events
More
Interviews
Live
Learn
Training
Career
Members
Blogs
Challenges
Certification
Contribute
Article
Blog
Video
Ebook
Interview Question
Collapse
Feed
Dashboard
Wallet
Learn
Achievements
Network
Refer
Rewards
SharpGPT
Premium
Contribute
Article
Blog
Video
Ebook
Interview Question
Register
Login
How To Find Odd And Even Number
WhatsApp
Shobana J
8y
3.8
k
0
3
25
Blog
Introduction
In this blog, I have explained about how to find out if a number is odd or even.
Software Requirements
Turbo C++ OR C
Programming
#include <stdio.h>
int
main()
{
int
n;
printf(
"Enter an integer\n"
);
scanf(
"%d"
, &n);
if
(n%2 == 0)
printf(
"Even\n"
);
else
printf(
"Odd\n"
);
return
0;
}
Explanation
From the programming, the number can be found out as odd or even.
Output
Conclusion
Thus, the program has been created.
odd or even number
C
People also reading
Membership not found