Lee Newberg <git...@quantconsulting.com> added the comment:
>This sounds interesting, but also rather similar to what the >`limit_denominator` method can get you. `Fractions("0.17").limit_denominator()` and `Fractions("0.17").limit_denominator(n)` for n > 28 do not give 1/6. So, I'd have to guess at n until I get 1/6. Instead, I'd like to have the digits actually presented "0.17" determine the interval [0.165, 0.175) which then determines the fraction. In particular, "0.170" would give a different answer ... a fraction within [0.1695, 0.1705). ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue46780> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com