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.
Interpreting instructions in a real-world application is not always easy either. I like to think of these as practice for dense or unclear legacy code or hard to read documentation. It is also often the case that the author's first language is not English, in which case I'm sure a suggestion for clearer instruction would be helpful
Thanks!
Fixed.
Hmm... You might be right. I believe the wording might've been different at the time I solved it, so I'll admit that I jumped the gun here... My mistake.
Nevertheless, I didn't close the issue initially, because I think we both agree that the description is inadequate and needs to be changed to minimize confusion.
Thank you for your response.
I do not equate "non-string integers" to "string integers". Please read the kata description carefully, especially where it says "...subtract this FROM the total of the string integers".
The sentence "take the sum a and subtract it FROM b" equates to this: b - a
while the sentence "take the sum a and subtract b" equates to this: a - b
How do you equate "non-string integers (sum)" (from description) to mean "string integer sum" (your interpretation) ?
The description is far from ideal, but it's not inaccurate to my knowledge.
Kata description does not accurately describe expected result. From the kata description: "add up the non-string integers and subtract this from the total of the string integers."
This would mean **(string integer sum) - (non-string integer sum) = result
However, when attempting the kata and looking at the sample tests provided, it is clear that the actual expected solution is the opposite:
**(non-string integer sum) - (string integer sum) = result
To resolve this issue, the kata description should read: "add up the non-string integers and subtract the total of the string integers."
Or, alternatively: "add up the string integers and subtract this from the total of the non-string integers."
You would never need to calculate whether the shark reaches your starting position to solve this one. You are correct in saying that if the shark reaches the pontoon first, you haven't made it in time. That is the reason for my issue. The test cases test for that exact condition, but the description does not match. Nothing needs to be added to the description, see my original comment for the simple fix.
Done.
The kata description should mention expected output. From the docs; "The description should clearly state all requirements the user is expected to fulfill to complete the kata."
The description clearly states what inputs to look for, but does not specify or even allude to an expected output.
make sure you check that n!=0, otherwise you will have an endless loop that would cause the timeout. otherwise, idk either
Perhaps this would have been better as a suggestion, and not an issue. I still believe it is important for the kata description to accurately lay out what is expected. I like having to puzzle out solutions too, but this is a case of being asked to solve the wrong thing.
This comment is hidden because it contains spoiler information about the solution
Personally, I think it's a trick to solve this question, rather than a issue.
Although the variable name is bad, but the description says:
So it really doesn't need to concern.
Loading more items...