+ 4
Why is my code giving error?
Says unexpected error on line 11 but there is nothing there https://code.sololearn.com/Wz1Ri94E7s8Y/?ref=app
4 ответов
+ 5
Just use onclick = "comp()"
In place of onclick = "function comp()"
+ 4
<button type="button" onclick="comp()">Compare</button>
+ 3
Thank you everyone
+ 2
onclick="comp()"
not:
onclick="function comp()"