Ad
  • Default User Avatar

    Do you have any advice? Seems to me impossible to solve in O(n).

  • Default User Avatar

    Actually I was wrong, both test are ok. The suggestion of Codestar187 goes in the right direction.

  • Default User Avatar

    Hi, I have some trouble understanding the results:

    How come this is true? shouldn't be false?
    ['e', 'w', 'e', 'w', 'n', 's', 's', 'e', 'n', 'w']

    And shouldn't this one be true?
    ['e', 'w', 'e', 'w', 'e', 's', 'n', 's', 'e', 'w']