You can google for "big integer" libraries written in C if you need support for complicated operations. Here is one way you can do it. Define a big integer to be an array of digits, then implement the operations that you need. Addition/multiplication by a constant/ division by a constant are straightforward to implement. For multiplication and division you can use long multiplication/division algorithm (i.e., grade school multiplication/division). You can do square root using binary search. And so on.
On Feb 3, 8:44 am, "kamalakannan .h" <[EMAIL PROTECTED]> wrote: > hellow, > i am doing a program which deals with 128 bit numbers.i want to > store a 128 bit in a variable, as we know all the data types in c offer less > than 80 bits. now how do i create a 128 bit data type for my program. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
