3 ms·
Not to mention no units on the timings, and no explanation as to why the heck you'd want to calculate 2^100000. (Or is that just a convenient way to construct
by colomon 15y ago
Not to mention no units on the timings, and no explanation as to why the heck you'd want to calculate 2^100000. (Or is that just a convenient way to construct a very long list?) Glad I wasn't the only one puzzled by it.
Edited to add: Ah, based on other comments, it's constructing a list of 2^100000 of the same symbol, and then later on, 2^100000 - 1 of that symbol and 1 of another symbol. Which I guess is interesting, but doesn't seem wildly impressive?
- henning 15y agothe first time i read it, i thought he was computing 2^N and turning it into a list of digits. but, no, he was making a list of that length. so, if you're going to pose a challenge to people, you should clearly describe what you're doing and why.
- colomon 15y agoEspecially because once we've sorted out what he is trying to demonstrate (I think) it seems dead trivial to duplicate? I mean, the only thing stopping me from doing that same demo with blazing speed in the deadly slow Rakudo Perl 6 compiler is the speed of calculating 2^100000.... PS For what it's worth, I'm guessing he's doing something more interesting than the dead simple implementation I'm imagining...