Why Conditional Operator Is Not Working? | JS | SoloLearn: Learn to code for FREE!

-1

Why Conditional Operator Is Not Working? | JS

When I put numeric value in place of variable, it works! But when I use variable, it shows error, Why??? https://code.sololearn.com/W29bWk0rcN75/?ref=app

7/4/2020 7:42:16 PM

Himanshu Rai

4 Answers

New Answer

+1

Himanshu Rai put the semi colon after prompt("text) ;

0

Bagon okk. But can you answer why parentheses causing error? Or what is the problem these parentheses producing?