0
Returning smallest value
write a code that takes 3 non-equal integers and returns the smallest
1 ответ
+ 1
Going by short
// Using ? and :
int x, y, z;
int smallest = (x < y && x < z) ?x: ((y < z) ?y: z);
cout<<smallest;
// Output will be the smallest num