HiddenLayer555@lemmy.ml to Programmer Humor@lemmy.mlEnglish · 6 months agoWhy make it complicated?lemmy.mlimagemessage-square52linkfedilinkarrow-up11arrow-down10file-textcross-posted to: [email protected]
arrow-up11arrow-down1imageWhy make it complicated?lemmy.mlHiddenLayer555@lemmy.ml to Programmer Humor@lemmy.mlEnglish · 6 months agomessage-square52linkfedilinkfile-textcross-posted to: [email protected]
minus-squareThirdConsul@lemmy.mllinkfedilinkarrow-up0·6 months agolet ret = someCondition ? expensiveOperation() : otherOperation() ?
let ret = someCondition ? expensiveOperation() : otherOperation()?
Yeah. That works.