ios - How can I know where digits are on a double -


i display number according position of first uncertain digit.

hence number 203.32134 first uncertain digit being 0.01 display 203.321 (all digits plus first uncertain , second rounded.)

but not know how write string format %x.yf in order string like.

could help?

use nsnumberformatter , set minimum/maximum number of significant fractions.


Comments