answersLogoWhite

0

You could use an if, but the ternary operator is especially compact for this purpose:

result = a > b ? a : b;

User Avatar

Wiki User

14y ago

What else can I help you with?

Related Questions

Which among this greater -5 or plus 2?

2 of course. Because 2 is positive and -5 is negative and positive numbers are always greater than negative numbers.


Which number is greater than 0.833?

0.888, 4, and 3 million are among the infinite set of numbers greater than 0.833.


Three digit number greater than 500 has five consecutive numbers among its factors?

720.


Write a program large number and small number among n numbers by using If statement?

12


What is greater than 1 fourth less than 3 fourths and not 1half?

There are infinitely many such numbers. Among them is 0.26


Write a C program to find greater number among three numbers using for loop?

#include<stdio.h> void main() { int a[3],i,b; printf("Enter 3 numbers\n"); for(i=0;i<=3;i++) scanf("%d",&a[i]); b=a[0]; for(i=0;i<=3;i++) if(a[i]>b) b=a[i]; printf("The biggest number is %d",b); }


What is a three-digit number that is greater than 500 with 5 consecutive whole numbers among its factors?

Any multiple of 60 from 540 to 960


How do you write the word among?

among


How do you get the GCF of the numbers 48 and 88?

To find the gcf of 48 and 88, first write both the numbers in terms of their prime factors48=2x2x2x2x388=2x2x2x11Now find the common among them=2x2x2=8 = GCF


How many prime numbers are greater than 75?

Well, honey, there are 25 prime numbers greater than 75. You want the list too? Well, tough luck, I'm not here to hold your hand through the world of math. Just know that there are 25 of those bad boys hanging out above 75.


What numbers are square numbers from 1 to 100?

Among the whole numbers, these are:149162536496481100


How do you write a c program to find biggest among two numbers using conditional operator?

int max (int a, int b) { return a>b?a:b; }