Ad
  • Default User Avatar

    cool, why did I even bother with recursion

  • Default User Avatar

    Thank you, I get it now. I unconsiously declare self.page_index = page_index on my page_item_count method. Appreciate the help, the traceback msg wasn't as clear or maybe I'm just not experienced enough.

  • Custom User Avatar

    No, your code is wrong, you overwrite the value of page_index method in your page_item_count method. Not a kata issue.

  • Default User Avatar

    I have no idea what I did wrong. I kept getting a traceback for my code (Copied it below). I decided to forfeit the test, checked the test cases, tested them myself on another IDE, my code works fine.

    Traceback (most recent call last):
    File "/workspace/default/tests.py", line 16, in
    test.assert_equals(helper.page_index(0), 0, 'page_index returned incorrect value')
    TypeError: 'int' object is not callable