HiddenLayer555@lemmy.ml to Programmer Humor@lemmy.mlEnglish · 9 days agoWhy make it complicated?lemmy.mlexternal-linkmessage-square51fedilinkarrow-up1111arrow-down117file-text
arrow-up194arrow-down1external-linkWhy make it complicated?lemmy.mlHiddenLayer555@lemmy.ml to Programmer Humor@lemmy.mlEnglish · 9 days agomessage-square51fedilinkfile-text
minus-squareThirdConsul@lemmy.mllinkfedilinkarrow-up4·8 days agolet ret = someCondition ? expensiveOperation() : otherOperation() ?
let ret = someCondition ? expensiveOperation() : otherOperation()
?
Yeah. That works.