Q = int(input()) for q in range(Q): qry = list(map(int, input().split())) if qry[0] == 1: print(qry[1]+qry[2]) else: print(q+1)