[algogeeks] Re: MODULUS Don Tue Feb 21 08:00:42 2012
A 32-bit integer can not store numbers that large, so you need to use something with more than 32 bits. For your example, a 64-bit integer should work. Try using type "long long int". Some compilers call it __int64. If you need something larger than your compiler provides, you can use an extended precision library such as NTL. Don On Feb 21, 8:40 am, Anurag Gupta <[EMAIL PROTECTED]> wrote: > how can we take mod by a very large number > for example 10000000000283 > int mod = 10000000000283; > ans % mod > > is not working > > Please Help -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to this group, send email to [EMAIL PROTECTED] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.