送交者: steven 于 2009-10-14, 02:36:10:
回答: 史迪文等没明白我的意思,写个程序算123456789123456789*987654321987654321 由 Nixrreg 于 2009-10-14, 00:03:25:
The implementation of multiplication in computer, especially on the chip level, usually only implement simple multiplication algorithm with the bit restriction. It is because the complicated multiprecision algorithm requires extra-accounting steps to manage data structures and memory usage and etc. These accounting steps also takes time, therefore, for small number say in the range of 2^64, there is no need for that, and in fact, it will only make the it slower. However, the typical algorithm including the one presented by “屎叫兽" requires O(n^2) steps, so for the number of 2^4096, “屎叫兽"'s method require 4096^2. He's so call speed algorithm only provides a linear speed up, so essentially, it is the trivial shift and add algorithm. It is meaningless.
As for kind,
you can specified in FORTRAN like: