+ 2
How do i make the computer the understand that i want to add the numbers got from prompt command & not concatenate them??
Plz refer to the code... https://code.sololearn.com/Ww6bd9kJD9tc/?ref=app
4 ответов
+ 5
You just need to wrap both the prompt() inside Number(), and it's done!
+ 5
var a=parseInt(prompt("Enter a number."));
var b= parseInt(prompt("Enter a number."));
document.write(a+b);
+ 2
Thankz guyz... This is the reason i love sololearn... quick help!!.... thankz everyone
+ 2
😀