Answers for "~ operator c programmin"

C
4

c ? operator

/* The expression a ? b : c evaluates to b if the value of a is true, 
 * and otherwise to c
 */

// These tests are equivalent :

if (a > b) {
    result = x;
}
else {
    result = y;
}

// and

result = a > b ? x : y;
Posted by: Guest on September-16-2021
1

c ? operator

? : Conditional Expression operator
If Condition is true ? then value X : otherwise value Y

y = x==0 ? 0 : y/x
Posted by: Guest on June-21-2021

Code answers related to "C"

Browse Popular Code Answers by Language