I came to this sollution only after having performance issues with 2 perfectly valid ones. This an 8-kyu kata, not a math contest.
That is one line?
Great! Now I know about array_values. Thanks.
Same but in just one line xD
very clever. I forgot the only integers in binaries are 0 and 1.
it is not lol))
I'm having a code'garms right now
doh! I hate when I leave the redundant bits
I do know regex :) What I didn't know was how to manage gsub with it and it is actually more difficult to read what is considered the top answer.
can someone explain this
This is to wasteful to be a best practice imo...
Concept is clever though.
Which means I'm NOT lazy! I knew it this whole time!
Because most people are lazy ;-)
too much code golf and less BP
not many started from the end of the list. strange.