<div dir="ltr"><div>Correction. My example reused &quot;val&quot; This is what I should have typed:<div><br></div><div><div style="font-size:13px"><b>    let foo = </b></div><div style="font-size:13px"><b>        &quot;positive&quot; where ( bar &gt; 0 )  ?? </b></div><div style="font-size:13px"><b>        &quot;negative&quot; where ( bar &lt; 0 ) ?? </b></div><div style="font-size:13px"><b>        &quot;zero&quot;</b></div></div></div><div><b><br></b></div>Sorry for that. My mind seems to switch itself off whenever I submit to this list :)<div><br></div><div>Also, since my previous posts to this list about ternary and switch assignment, etc. I now feel that including the variable name in the bool side is useful. It would be a quick way to do the following sort of thing:<br></div><div><br></div><div><div style="font-size:13px"><b>    let foo = </b></div><div style="font-size:13px"><b>        &quot;positive&quot; where ( bar &gt; 0 )  ?? </b></div><div style="font-size:13px"><b>        &quot;negative&quot; where ( bar &lt; 0 ) ?? </b></div><div style="font-size:13px"><b>        &quot;animal zero&quot; where ( is_animal == true ) ?? </b></div><div style="font-size:13px"><b>        &quot;normal zero&quot;</b><br></div></div><div><b><br></b></div><div><br></div><div><br></div><div><br></div></div>