Valhalla Legends Archive

Programming => General Programming => C/C++ Programming => Topic started by: shout on May 10, 2005, 11:22 AM

Title: Arithmetic in Arrays
Post by: shout on May 10, 2005, 11:22 AM
Anyone know how to perform modulus on arrays treated as a large integer? I am creating an SRP implementation and I do not want to impletment some large integer class for just modulus and pow.
Title: Re: Arithmetic in Arrays
Post by: K on May 10, 2005, 11:28 AM
Not going to be easy.

http://ebooks.servegame.com/addweshacdel/059.htm
Title: Re: Arithmetic in Arrays
Post by: Adron on May 11, 2005, 11:32 AM
Quote from: Shout on May 10, 2005, 11:22 AM
Anyone know how to perform modulus on arrays treated as a large integer? I am creating an SRP implementation and I do not want to impletment some large integer class for just modulus and pow.

What would be involved in implementing some large integer class apart from the basic things you need for modulus and pow? To multiply and divide numbers, you need to be able to compare, shift, add and subtract. Isn't that just what a basic large integer class supports?