C Program to find maximum between two numbers using conditional operator
C program to
find maximum between two numbers using conditional operator
Write a C program to enter two numbers and
find maximum between two numbers using conditional/ternary operator( ?: ). How
to find maximum or minimum between two numbers using conditional operator in C
program.
Example:
Input first number: 10
Input second number: 20
Output maximum: 20
Example:
Input first number: 10
Input second number: 20
Output maximum: 20
Required knowledge
Basic C programming, Conditional operator
Program to find maximum
using conditional operator
|
Output
Enter
two numbers: 10
20
Maximum between 10 and 20 is 20
20
Maximum between 10 and 20 is 20
Comments
Post a Comment