How to get an output of number form of a given TOTAL digit?
For example, a total digit of 3, then one get
1.00
for1.
10.0
for10.
100.
for100.
and so on.
I try NumberForm[1., 3]
but only get 1.
. Of course I can use NumberForm[1., {1, 2}]
to get 1.00
but then for 10.
I need to use NumberForm[10.,{2, 1}]
and for 100
I need to use NumberForm[100., {3, 0}]
, which is not automatic and depends on the certain number i input. So is there any way to get an output of number format with a fixed TOTAL digits that does not depends on the specific input?