bash if then else one line

C++
if [[ CONDITION_STATEMENT ]]; then SOME_CODE; else OTHER_CODE; fi
Source

Also in C++: