2 ms·
The shell command is very readable. a && b && c is a common idiom for "stop if any step fails". In the shell language && and || are more like control flow conc
by PhilipRoman 3y ago
The shell command is very readable.
a && b && c is a common idiom for "stop if any step fails". In the shell language && and || are more like control flow concepts, rather than binary operators.
And a && b || c is a universal "ternary operator" (with one minor deviation) idiom across many languages, not just the shell