Tell me more ×  Have a quick JS question. What is the difference
between math.round and parseInt?  I made a JS script to sum the
inverses of prompted numbers:      <script
type="text/javascript">     var numRep = prompt("How many
repetitions would you like to run?");     var sum = 0;      var
count = 0;     var i = 1;     //variable i becomes 1      while
(i <= numRep)  {//  repeat 5 times         var number =
prompt("Please enter a non zero integer");
document.write("Invalid Input <br>");
document.write("The inverse is: " + 1/number + "<br>");
sum = sum + (1/parseInt(number));  //add number to the sum
i++; //increase i by 1      if (sum==0){     document.write("You
did not enter valid input");}     else { document.write("The sum
of the inverses is: " + sum);  //display sum  and it uses
parseInt. If I wanted to makeit use math.round, is there
anything else I need to do so that It knows to limit the number
of decimal places accordingly?  In other words, does math.round
hav