We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
You are correct. I forgot about this: In the input data, "The leftmost value represents the bottom plate of the pile".
Which means that you have to read the data and push them into a stack first, reversing the input order. Then you start dividing them into smaller stacks.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Waiter
You are viewing a single comment's thread. Return to all comments →
You are correct. I forgot about this: In the input data, "The leftmost value represents the bottom plate of the pile".
Which means that you have to read the data and push them into a stack first, reversing the input order. Then you start dividing them into smaller stacks.