6 ms·
It should take 415kB to store a million digit number, and the algorithm only needs to keep two of them. So, 1MB total to calculate a million digits of pi. I w
by ajennings 7y ago
It should take 415kB to store a million digit number, and the algorithm only needs to keep two of them. So, 1MB total to calculate a million digits of pi. I wonder if there are a lot of temporary allocations that build up until they get garbage collected.
- sp332 7y agoNot sure what it is exactly, but forcing a garbage collection (using the "minimize memory usage" button in about:memory) doesn't make any difference.