Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
Haha, definetly no.
I am a one-liner just for fun. I have solved most of the katas with one-liners.
It made a little bit harder to solve the katas but I learn a lot with this. :)
My initial instinct was to implement something similar to yours but decided the code was too complex and doing too many unnecessary calculations. So I switched it to a simple substitution and capped my table to meet the requirements of the kata (actually I over-engineered it by one entry). This doesn't make mine right and yours wrong, we're just solving it around different priorities.
There is a limit in the input range (or should be) for that to be true.
I'd probably do a couple of things differently if this was production code, but I would keep the symbols in an encoding table. Why calculate the same values over and over again?