Tacko Spolsky Recommends: www.devlabs.ninja
The object of the puzzle is to manipulate url parameters in a way to make your name (or any other string) appear on the screen. It was invented by the Trello team for a job opening for a ECMAScript developer (direct link to the puzzle: https://taco-spolsky.github.io/).
It took me awhile to get Tacos recommendation, but it was fun to play around with JavaScript.
Here are the some tips:
Taco generally avoids the keyword var
and puts all his code
in the global namespace. To overwrite the name
variable, you just have to
find where it is set.
There is no number which is <,>,= to any other number at the same time.
Maybe there are some others valid values in the levelMap
?
Sometimes it makes sense to be sure about a functions return value, especially if we are
going to use the automatic type conversion to boolean: if(-1) { console.log('is true') }
Have fun solving the puzzle, here is the solution for www.devlabs.ninja: https://goo.gl/UJ9bS5
My recommendation for Taco is to move to the automotive industry: right now, some major manufacturers are desperately looking for skilled programmers who can disguise the code in a way he can do it.