without if- elseProgram to Check Even or Odd
C Programming Language / Decision Making of C Language
936Program:
#include"stdio.h" int main() { int number; printf("Enter an integer: "); scanf("%d", &number); (number % 2 == 0)? printf("%d is even.\n", number): printf("%d is odd.\n",number); return 0; }
Output:
Enter an integer: 15 15 is odd. Press any key to continue . . .
This Particular section is dedicated to Programs only. If you want learn more about C Programming Language. Then you can visit below links to get more depth on this subject.
# C Tutorials
# JAVA Tutorials
# HTML Tutorials
# Computer Fundamental
# Data Structure
# DBMS Tutorials
SQL
# C# Language
# R Language
# PHP
# Python
# Vue JS