#!usr/bin/python #coding=utf-8 def add(a,b): return a+b ncase=int(raw_input()) for i in range(ncase): str=raw_input() print eval(str)