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.
Basic tests use this:
['|', 'J', '|', '|'],
['|', '|', '|', 'J'],
['...', '...', '...', '...'];
But actual tests use this ("random"):
['|', '...', '|', '...'],
['...', '...', '|', 'J'],
['...', '...', '...', '...'];
Trimmed hair ("...") can also occur in the "curled hair", as well as in "chin hair", right?
In my initial solution I didn't expect there will be trimmed hair ("...") present in "curled hair",
but only "J" and "|" since trimmed hair is not included in basic test cases.
Nice kata. Tnx!
Instructions and Test Cases really should include the requirement of
beard hair having "trimmed chin hair" as well.
Was kind of frustrated when my test failed because of the absence
of specs in the Instructions.
Yeah, likewise!
Good point. I find that the greatest enemy of progress is not willing to lose and learn from a defeat. It coincides somewhat with what you said. Greatest gains do come from facing situations above our skill level and giving our best in trying to overcome them. That's why I like CW, it gives us a lot of tools for improvement.
I'm glad it worked out for you. (thumbsup)
I'm currently focused on doing/learning as much as I can and enjoying it in the meantime. ^^
The more I use it, the more I like it. I'd say that's a mark of a good product. ^^
In your last sentence you pretty much summarized my current position, although I feel
confident enough with my current Ruby skillset.
Thanks one more time. Always happy to chat with a fellow FotNS fan. :D
Thank you for taking the time to answer the question thoroughly. Much appreciated!
I read only Ruby solutions, since I'm only fluent in it atm.
I get your perspective, it's a good analogy. :) As far as production code goes, the m.o. you stated is the way it should be done, I agree.
I just might take you up on that offer. I've seen some of your solutions and like them a lot (hence the first message :) ).
Hi,
just wondering, if you had to put this solution to production code,
would you leave it as is, or would you try to make it more readable?
Thanks.
D.
+1. I'd rate it as 6th kyu, but wouldn't object if it was classified as 5th kyu as well.
It's definitely not 7th kyu.
Hi! That's correct as well. ^^ This kata didn't require class vars though.
In Ruby '$' symbol is used for defining global vars. You use '@' when declaring instance variables.
Excellent kata! Thank you very much. Namaste.