■ 문제해설 각 기능별로 (push, pop, size, empty, top) 함수로 구현하였고, stack이 비어있는 경우에는 len(stack) == 0을 이용하여 조건문을 구성하였다. ■ 문제해답 import sys input = sys.stdin.readline n = int(input()) stack = [] def push(x): return stack.append(x) def pop(): if len(stack) == 0: return -1 else: return stack.pop() def size(): return len(stack) def empty(): if len(stack) == 0: return 1 else: return 0 def top(): if len(stack) == 0:..