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.
Please say which language you're using when posting (here it's easy to see you use Python, but anyway it's a good habit to have). This may be helpful: Troubleshooting Your Solution.
This log is a crash log from Python's interpreter that tells you that at the seventh line of your code the programs tries to access to a list's index out of bound.
Ok. Then what is the test-case, which points out adequately to my bug?
Not sure what the issue is:
a) there's a bug in your code, which the stack trace points out adequately (
i
is going out of bounds)b) you need not worry about
camel_sol
, as this is a function internal to the tests (it is used to compute the correct output to compare your solution against)c) The task is neither stupid, nor is the description vague. I understand you may be frustrated that you're having to deal with bugs in your code, but that's just a normal aspect of programming, and is no reason to blame the kata.
Traceback (most recent call last):
File "tests.py", line 21, in
test.assert_equals(to_camel_case(word), camel_sol(word), "to_camel_case("+word+") did not return correct value")
File "/workspace/default/solution.py", line 7, in to_camel_case
if text_list[i] == '_' or text_list[i] == '-':
IndexError: list index out of range
What does it mean
camel_sol(word)
during the test? Quite stupid task with vague description