Math question

Results 1 to 2 of 2

Thread: Math question

  1. #1
    BobbyK Guest

    Default Math question

    Actually 2 questions. First, is there a way I can get a number like 37.33333... to round up to 37.5. Second, is there a way to drop off all but 2 decimal points (ex. 37.33333... would be 37.33). Thanks in advance.

  2. #2
    Join Date
    Dec 1969

    Default RE: Math question

    quick answer to the second qustion<BR><BR>convert it to a string.<BR>find the point with indexOf(&#039;.&#039;);<BR>do the math to find the point you need to chop it at.<BR>use substring(0, myPoint) to cut it down. parseFloast() it back if necessary.<BR><BR>j<BR><BR>j

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts