Is there a way to convert a mpz_t variable to unsigned long long in C?How about the other way around,from ull to mpz_t?The gmp library doesn’t support this as ull are part of C99.
I found this but it’s in c++,and I don’t know how to code in c++.Thanks in advance.
Is there a way to convert a mpz_t variable to unsigned long long in
Share
Here are some functions for translating between
unsigned long longandmpz_t. Note thatmpz2ullwill smash your stack if the number is too big to fit into anunsigned long long: