in reply to Re^3: How does Math::GMP overload the assignment operator ? (more guessing)
in thread How does Math::GMP overload the assignment operator ?
Math::GMPz achieves the same result with:C:\>perl -MMath::GMP -le "print int(Math::GMP->new(311) ** 100);" 385227681
though, in this very last example, $x is a Math::GMPz object, not an IV.C:\>perl -MMath::GMPz=":mpz" -le "print Rmpz_get_ui(Math::GMPz->new(31 +1) ** 100);" 385227681 alternatively: C:\>perl -MMath::GMPz -le "$x = (Math::GMPz->new(311) ** 100) & 429496 +7295; print $x;" 385227681
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: How does Math::GMP overload the assignment operator ? (more guessing)
by jcb (Parson) on Nov 10, 2020 at 04:09 UTC | |
by syphilis (Archbishop) on Nov 10, 2020 at 11:52 UTC | |
by Haarg (Priest) on Nov 10, 2020 at 19:54 UTC | |
by syphilis (Archbishop) on Nov 11, 2020 at 00:55 UTC | |
by jcb (Parson) on Nov 11, 2020 at 00:52 UTC | |
by syphilis (Archbishop) on Nov 11, 2020 at 01:30 UTC |