[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: Help with bigbnum

Todd

5/5/2007 2:34:00 PM


--- Victor Reyes <victor.reyes@gmail.com> wrote:

> Todd, thank you for the example. I truly appreciate
> it. I'll give it a try.

Don't get too excited. On my system (2.4GHz Intel),
it looks like it would take about 2.5 hours to compute
(I didn't test it to see if it would even work).
Also, it is most likely faster to multiply by larger
numbers than 2.

2**32582656 == 4**16291328 == 16**8145664 ==
256**4072832 == 65536**2036416 and so on

Broken down, it's:

2**32582656 == 2**(2**10 * 3**2 * 3541) ==
( (2**(2**10))) ** (3**2) ) ** 3541

I'm guessing now matter how you cut it up, you will
get the same error, though :( Maybe ruby chokes at
around a million digits.



____________________________________________________________________________________
Food fight? Enjoy some healthy debate
in the Yahoo! Answers Food & Drink Q&A.
http://answers.yahoo.com/dir/?link=list&sid...