Ad
  • Custom User Avatar

    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.

  • Custom User Avatar

    Ok. Then what is the test-case, which points out adequately to my bug?

  • Custom User Avatar

    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.

  • Custom User Avatar

    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