inline if else code example
Example 1: js inline if
var a = 2;
var b = 3;
var c = ((a < b) ? 'minor' : 'major');
Example 2: c# if statement one line
someValue = condition ? newValue : someValue;
var a = 2;
var b = 3;
var c = ((a < b) ? 'minor' : 'major');
someValue = condition ? newValue : someValue;