At the moment, there's no way to print a fixed number of digits, but it won't be hard to do -- a simple way would be to replace the last begin-while-repeat look with a do-loop of the number of digits you want and strip out the stuff dealing with M.
It's something I hope to get around to eventually -- it's in the ANS standard with the SET-PRECISION word. I'll probably make it possible to have a set number of significant digits or to use the current method. -Leon On Saturday, September 04, 2010 02:31:16 pm you wrote: > Yes, 0.1 is $3dcccccc = 0.09999999403953552 > from that the result will be 3.14158984478e+/-15 (shall be > 3.1415926535e+/-15). > Our result is 3.1415851, or 3.1415874 - so quite precise. However, I > would simply recommend to print with 4 decimal places only. For > atmega users -3.1415E-27 might be ok, I guess. And nobody will be > nervous (:-)). Q: can we set the number of decimal places to be > print somehow? Pito ------------------------------------------------------------------------------ This SF.net Dev2Dev email is sponsored by: Show off your parallel programming skills. Enter the Intel(R) Threading Challenge 2010. http://p.sf.net/sfu/intel-thread-sfd _______________________________________________ Amforth-devel mailing list Amforth-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/amforth-devel