Hi,

I java, under BigInteger class, there is a function called modpow, http://java.sun.com/j2se/1.4.2/docs/api/java/math/BigInteger.html#modPow%28java.math.BigInteger,%20java.math.BigInteger%29

It allows us to answer things like 99999^9999 % 78 very quickly. But I am unable to find one for c++.

Thanks

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.