in reply to [perl 6] re reduction operators
It's sometimes easier to just join the numbers form 1 to 300000 and take the first 10^6 digits of that.
It also helps to have a repl-loop so you can quickly try out how long the concatenation of 1..300000 takes and correct the number to a better approximation in a few steps.
(... types some quick lines to an interpreter ... things like # ; <@":"0 i.3e5 and 01234567891011121314151617181920212223242526272829303132333435363738394041424344 flicker on the screen ... yep, 1..2e5 is enough)
Yeah, I'm not a lazy languages guy. Quite the opposite. Especially for quick calculations like this. How did you guess?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: [perl 6] re reduction operators
by blazar (Canon) on Sep 18, 2007 at 15:23 UTC |