Lena@gregtech.eu to Programmer Humor@programming.devEnglish · 3 days agoPerfect relationshipgregtech.euimagemessage-square11linkfedilinkarrow-up1232arrow-down133file-text
arrow-up1199arrow-down1imagePerfect relationshipgregtech.euLena@gregtech.eu to Programmer Humor@programming.devEnglish · 3 days agomessage-square11linkfedilinkfile-text
minus-squareMightBeFluffy@pawb.sociallinkfedilinkEnglisharrow-up20·edit-23 days agoA ternary is a short hand to assign a value based on a true/false statement let a; if(isTtrue) a=2 else a=9 Becomes let a = (isTrue) ? 2 : 9
A ternary is a short hand to assign a value based on a true/false statement
let a; if(isTtrue) a=2 else a=9
Becomes
let a = (isTrue) ? 2 : 9