1. mannaggia's Avatar
    Hello everybody!
    First of all, I'd like to thank the editors of this valuable blog and I'd like to apologize for my poor English.
    I'm developing an app (using app inventor) for which I need to round to two decimal places the input entered by the user with "n" decimal places. To do this, I used "format as decimal". I noticed, however, a behavior I did not expect; for example, by entering 38.035, "format as decimal" returns 38.03. Likewise, 38.135 is rounded to 38.13, 38.235 -> 38.23. But with 38.335 rounding is, as expected, 38.34. Other examples: 0.015 -> 0.01, 0.215 -> 0.21, but 0.315 -> 0.32, as expected.
    I've read somewhere that App Inventor follows the rounding convention known as "half-to-even", but the tests I've done (like the ones I listed here) do not support this hypothesis. So I'd like to ask: what's wrong? Is there anyone who gets the same results?
    Thank you ...
    03-31-2013 04:36 AM

Similar Threads

  1. somone please help me with rongdroid
    By owensch1 in forum Verizon Droid Incredible
    Replies: 6
    Last Post: 08-03-2010, 11:01 PM
  2. Im so lost... please help me
    By MissLaniS in forum Wallpapers, Ringtones, and Themes
    Replies: 3
    Last Post: 05-21-2010, 03:16 PM
  3. Please help me!!! =(
    By yojosefo#AC in forum T-Mobile G1
    Replies: 3
    Last Post: 01-17-2010, 11:40 PM
  4. Please help me decide.
    By oberhaus#AC in forum The Android Central Lounge
    Replies: 17
    Last Post: 01-05-2010, 09:24 AM
  5. Please help me!!! =(
    By yojosefo in forum General Help and How To
    Replies: 0
    Last Post: 10-12-2009, 09:31 AM
LINK TO POST COPIED TO CLIPBOARD