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.
Hahaha, I wrote that comment 3 years ago! I resat the kata and tried again, this time with no hiccups.
Both Python and JS version needs better handling inside the transition function. Passing in unexpected values just throws an exception.
You passed in a invalid symbol.
Why does JS version have completely different transition function return format? Language versions should have the same mechanism whenever possible.
Hey,
I did the same way. For me - beginner in python - very easy to to read the code and see what is happening.
Brilliant. I'm so mad I didn't think to see how to convert base 16 in python. This is much cleaner than my solution.
I keep getting an error
when calling the
transitionFunction
, which is really annoying. My solution works for the given tests and I cannot see what is wrong with me calling the way I do.Need more clarification on what types of attribute access to record.
For example, I assumed access to init before calling it also needs to be recorded.
fixed.
thanks!
minor typos:
Turing is a proper noun, ao should have a capital T
transition
character
done
noted.
done
done
This comment is hidden because it contains spoiler information about the solution
( JS )
T[[s,q]] = ...
This. Is. Horrible.
Object
property keys can only beString
s. This syntax is valid, it's very, very Clever, and it relies on implicit coercion and it's completely unmaintainable. Also, I don't want to think about what happens whens
orq
happens to be','
. Or whenT
is aMap
instead of anObject
, which might at some point be a desirable optimisation.If you understand fully and completely when and how coercion works, and any and all collaborators agree this is a good idea ( with the same deep understanding of coercion ), and this behaviour is extensively, exhaustively documented, you might get away with it as long as nobody else ever needs to maintain your code. ( I would never ever want to be one of those collaborators. ) Given that the platform and the testing framework might at some point get upgraded and require maintenance on your testing code, and you might disappear from CodeWars and some poor sod other than you might have to perform that maintenance, please don't do this. It's begging for bugs, which might leave the kata non-functional at any moment.
Loading more items...