conditional operator

JavaScript
var age = 26;
var beverage = (age >= 21) ? "Beer" : "Juice";
console.log(beverage); // "Beer"

Source

Also in JavaScript: