Piling Up!
-
Practice>Python>Collections>Piling Up!hackerrank.com 2019. 2. 28. 13:13
hackerrank.comPiling Up!Problem link : https://www.hackerrank.com/challenges/piling-up/problemDifficulty : Medium TipSimplify the rule of problemIf we assume s[] is a all of sideLength, s[0] or s[-1] should be biggest number in sThis is a key to solve problemTo access easily to head and tail, deque is good to useSolution from collections import deque T = int(input()) def stack(n , s): for max_in..