Computer Science, asked by manyarao2945, 10 months ago

Write a program to find out maximum of three numbers using conditional operator

Answers

Answered by Priya981012
3

In this Program we have used the conditional operator for comparing biggest of three numbers.

# include <stdio.h>

void main()

{

int a, b, c, big ;

printf("Enter three numbers : ") ;

scanf("%d %d %d", &a, &b, &c) ;

big = a > b ? ( a > c ? a : c) : (b > c ? b : c) ;

printf("\nThe biggest number is : %d", big) ;

More items...

Hope it heps you

Similar questions