Skip to content

Commit e833a38

Browse files
Merge pull request seeditsolution#42 from praveenkumar5108/patch-2
evnodd
2 parents 31bff73 + a5a5e3d commit e833a38

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

evnodd

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
#include <stdio.h>
2+
int main() {
3+
int num;
4+
printf("Enter an integer: ");
5+
scanf("%d", &num);
6+
7+
// True if num is perfectly divisible by 2
8+
if(num % 2 == 0)
9+
printf("%d is even.", num);
10+
else
11+
printf("%d is odd.", num);
12+
13+
return 0;
14+
}

0 commit comments

Comments
 (0)