You are viewing a single comment's thread. Return to all comments →
p=[] for _ in range(int(input())): l=list(map(int,input().split())) if l[0]==1: p.append(l[1]) if l[0]==2: p.pop(0) if l[0]==3: print(p[0])
Seems like cookies are disabled on this browser, please enable them to open this website
Queue using Two Stacks
You are viewing a single comment's thread. Return to all comments →