How do I make sure that str() doesn't return exponential notation? On Friday, April 16, 2021 at 11:43:22 AM UTC+3 [email protected] wrote:
> In that case, I think the simplest option would be to parse > str(float). Some split() and strip() operations should get you want > you want, or just use a regex. > > Aaron Meurer > > On Thu, Apr 15, 2021 at 11:56 PM Paul Royik <[email protected]> wrote: > > > > One digit. Ignore scientific notation. > > > > On Friday, April 16, 2021 at 1:23:53 AM UTC+3 [email protected] wrote: > >> > >> How would you count small numbers like 1.1e-30. Is that 1 digit or 31 > >> digits after the decimal? > >> > >> Aaron Meurer > >> > >> On Thu, Apr 15, 2021 at 2:31 PM Paul Royik <[email protected]> wrote: > >> > > >> > Rational(1,2).evalf(), how do I get 1 here (since 0.5 has 1 digit > after the dot)? > >> > > >> > -- > >> > You received this message because you are subscribed to the Google > Groups "sympy" group. > >> > To unsubscribe from this group and stop receiving emails from it, > send an email to [email protected]. > >> > To view this discussion on the web visit > https://groups.google.com/d/msgid/sympy/73ee2ab4-7b12-4938-a1ed-079b3a33fc14n%40googlegroups.com > . > > > > -- > > You received this message because you are subscribed to the Google > Groups "sympy" group. > > To unsubscribe from this group and stop receiving emails from it, send > an email to [email protected]. > > To view this discussion on the web visit > https://groups.google.com/d/msgid/sympy/643b8e44-91f1-475f-87ed-f444d584bbaen%40googlegroups.com > . > -- You received this message because you are subscribed to the Google Groups "sympy" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/08377bfa-5f3c-4965-ae9e-db0ea3bf7a42n%40googlegroups.com.
