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.
Sure thing. Marking as resolved. Only minor thing is that under Behavior one of the black boxes showing
str
is stretching the entire width of the description, making it look a little odd, but maybe that's a limitation of markdown. Anyways, keep up the good work.Cool. I appreciate the quick response. And the issues are rather minor, especially considering English isn't your native language. Below are other changes I'd suggest making. I'm a native speaker, but I'm sure my English isn't perfect, so feel free to accept or reject any of the suggestions.
Line 1:
Line 2:
Comments in third code example:
Line after third code example:
Line after fourth code example:
while
judges condition before perform code execution,do..while
judges condition after code run one time." -> "The difference is thatwhile
judges the condition before code execution, anddo...while
judges the condition after the code executes at least one time."Two lines down:
Task:
Your task is to create a function, padIt, that has two parameters:
str
- a string representing the string to pad.n
- a number representing how many times to pad the string.Behavior of the function:
You need to write a loop statement within the function that loops
n
times. Each time through the loop it will add one "*" tostr
, alternating on which side it is padded: the first time will add a "*" to the left side ofstr
, the second time will add a "*" to the right side, and so on.Finally, return the padded string.
There are minor issues with the English, primarily the use of verb tense. For instance, "the example above can write like this:" should have been "the example above can be written like this:" The kata itself is a good one for beginners. It's just a little jarring reading through the text.