25/05/2016, 11:42 PM
So, I joined hackerrank lately, after learning a bit of C, Python, and Java after ruby, so I could focus on learning algorithms, instead of 9001 languages. I decided to dabble in their bash section for a while, since my hackerrank is on my linkedin profile, and I'd like for potential employers to be able to see my mad bash skills. Thinking I was hot spoon after getting up pretty decent on the bash leaderboards, I decided to try the "Hard" section of their bash... section. I was presented with this marvelous challenge:
Your eyes do not deceive you, folks! They want you to make a mandelbrot generator in bash! Holy spoon! Needless to say, I just nope'd the fudge out of that, and stuck to moderate challenges (This is actually the only hard one)
There was one coder that solved the test by generating HASKELL code to a file, and using the HASKELL program to dump the fractal, instead of using bash.
Also, hackerrank has a timeout rule, so this monstrosity of a script has to generate the fractal before the site decides that it is taking too long, and fails you for it!
Spoiler:
Code:
|
There was one coder that solved the test by generating HASKELL code to a file, and using the HASKELL program to dump the fractal, instead of using bash.
Also, hackerrank has a timeout rule, so this monstrosity of a script has to generate the fractal before the site decides that it is taking too long, and fails you for it!