+ 3
Can any one tell why the code below is not asking me the details.....????
4 Réponses
+ 7
what ''not asking me the details'' mean ?
please explain, maybe i can help you.
+ 2
???Maybe, You should use 'prompt' function to receive user's input.
+ 2
<script>
var a,b,c,d,e,f,g;
a=parseInt(window.prompt("Input First Number: "));
b=parseInt(window.prompt("Input Second Number: "));
c=parseInt(window.prompt("Input Third Number: "));
d=parseInt(window.prompt("Input Fourt Number: "));
e=parseInt(window.prompt("Input Fith Number: "));
f=a+b+c+d+e;
g=f/100;
alert("The total marks is"+f);
alert("The total percentage is " +g);
</script>
https://code.sololearn.com/WoRc35u2NNLN/#html
+ 1
Yup. For some reason you're trying to parse a bunch of strings to int, and I'm guessing you're assuming parseInt means "give me user input?"