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.
This. Is. Ruby!
Why does this work ? If I run it on and online editor the output is wrong
I thought of this, but i felt like a cheat to me, so i tried another method
Ruby lets you specify default values for a method's arguments---values that will be used if the caller doesn't pass them explicitly. This is done using the assignment operator
=
.same problem here ;/ only the first 2 tests get executed
because name of method is 'always'
could somebody explain to me why did the author assign n to nil when he passed it to the method always?
can anyone explain?
can anyone explain?