Ad
  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    The test with [s, s, s, t, n, s, s, s, t, s, n, s, s, s, t, t, n, s, t, s, n, t, n, s, t, n, n, n] is incorrect. It expects an index error (In python i'm throwing an Exception() to no avail) however you wont get an index error because there is a bad number. it reads 1, 2, 3 onto the stack and tries to duplicate but when reading the number after the duplicate command there is only '\n' which is supposed to be an error according to the description. I'm not sure where to go from here because while I do throw an exception the description for the test is wrong and its failing. Am I just missing something?

  • Custom User Avatar

    I like this solution. I had to go back and play with it a bit. Well done.