lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Can you set the decimal precision in Lua?

On Mar 31, 2013, at 9:28 AM, Mark Gabby <mwgabby@gmail.com> wrote:

A shorter explanation is that the fraction 1/10 cannot be exactly represented as a binary fraction.

The reason it looks exact earlier is that some less significant trailing digits are ignored by the print function.