Conditional Or Ternary Operator In C Code Example


Example 1: how to use ternary operator in c programming

int a = 10, b = 20, c;  c = (a < b) ? a : b;  printf("%d", c);

Example 2: ternary operator in c

c = (a < b) ? a : b;

Comments

Popular posts from this blog

Converting A String To Int In Groovy

"Cannot Create Cache Directory /home//.composer/cache/repo/https---packagist.org/, Or Directory Is Not Writable. Proceeding Without Cache"

Android How Can I Convert A String To A Editable