Problem:

Simple Calculator

Write a program which reads two integers a, b and an operator op, and then prints the value of a op b.

The operator op is '+', '-', '*' or '/' (sum, difference, product or quotient). The division should truncate any fractional part.

Input

The input consists of multiple datasets. Each dataset is given in the following format.

a op b

The input ends with a dataset where op = '?'. Your program should not process for this dataset.

Output

For each dataset, print the value in a line.

Constraints

  
 0 ≤ a, b ≤ 20000

No divisions by zero are given.

Sample Input 1

1 + 2
56 - 18
13 * 2
100 / 10
27 + 81
0 ? 0

Sample Output 1

3
38
26
10
108



Sample input:
1 + 2
56 - 18
13 * 2
100 / 10
27 + 81
0 ? 0


Sample output:
3
38
26
10
108

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()
    a = int(a)                   
    b =  int(b)
    
    

    if op == "?":
        break
    else:
        if op == "+":
            print(a+b)
        if op == "-":
            print(a-b)
        if op == "*":
            print(a*b)
        if op == "/":
            print(a//b)

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()   # 3変数ともに文字列として読み込む
    a =int(a)                   # a を整数に変換
    b = int(b)                   # b を整数に変換


    if op=="?": 
        break
    else: #opが"?"以外の時
        if op=="+":
            print(a+b)
        elif op=="-":
            print(a-b)
        elif op=="*":
            print(a*b)
        elif op=="/":
            print(a//b)

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()
    a = int(a)
    b = int(b)
    if op == "+":
        print(a + b)
    elif op == "-":
        print(a - b)
    elif op == "*":
        print(a * b)
    elif op == "/":
        print(a // b)
    else:
        break

Submission status: Accepted

Solution code:
import math
while True:
  x = list(input().split())
  a = int(x[0])
  op =x[1]
  b = int(x[2])
  if op =='+':
      print(a+b)
  elif op =='/':
      print(math.floor(a/b))
  elif op =='*':
      print(a*b)
  elif op =='-':
      print(a-b)
  elif op =='?':
      break

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()   # 3変数ともに文字列として読み込む
    a =int(a)                   # a を整数に変換
    b =int(b)                   # b を整数に変換


    if op=="?": # opが"?"の時は終了
        break
    else:    #opが"?"以外の時
        # ここ処理を書いてください
        # else のなかです。この通りのインデントを付けてください。
        if op =="+":
            print(a+b)

        elif op=="-":
              print(a-b)

        elif op=="*":
              print(a*b)

        elif op=="/":
              import math
              print(math.floor(a/b))
        else:
          print()

Submission status: Accepted

Solution code:
while 1:
    a=input()
    if '?' in a:
        break
    else:
        print(int(eval(a)))

Submission status: Accepted

Solution code:
while True:
    A, op, B = input().split()
    A = int(A)
    B = int(B)

    if op == "+":
        print(int(A + B))
    elif op == "-":
        print(int(A - B))
    elif op == "*":
        print(int(A * B))
    elif op == "/":
        print(int(A / B))
    elif op == "?":
        break

Submission status: Accepted

Solution code:
while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)
    
    if op=="?":
        break
    if op=="+":
        print(a+b)
    if op=="-":
        print(a-b)
    if op=="*":
        print(a*b)
    if op=="/":
        print(a//b)

Submission status: Accepted

Solution code:
while True:
    a,op,b=(input().split())
    a = int(a)
    b = int(b)
    if op =="?":
        break
    elif op =="+":
        print(int(a+b))
    elif op =="-":
        print(int(a-b))
    elif op =="*":
        print(int(a*b))
    elif op =="/":
        print(int(a//b))

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()   # 3変数ともに文字列として読み込む
    a =int(a)                   # a を整数に変換
    b = int(b)                   # b を整数に変換


    if op=="?": # opが"?"の時は終了
        break
    else: 
        if op=="+":
            print(a + b)
        if  op=="-":
            print(a - b)
        if op=="*":
            print(a * b)
        if op=="/":
            print(a // b)

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()   # 3変数ともに文字列として読み込む
    a =int(a)                   # a を整数に変換
    b = int(b)                   # b を整数に変換


    if op=="?": # opが"?"の時は終了
        break
    else:  #opが"?"以外の時
        # ここ処理を書いてください
        # else のなかです。この通りのインデントを付けてください。
        if op== "+":
            print(a+b)
        elif op== "-":
            print(a-b) 
        elif op== "*":
            print(a*b)        
        elif op== "/":
            print(a//b)
        else:
            print()

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()   # 3変数ともに文字列として読み込む
    a =int(a)                   # a を整数に変換
    b =int(b)                   # b を整数に変換


    if op=="?": # opが"?"の時は終了
        break
    else:    #opが"?"以外の時
        if op=="+":
            print(a+b)
        if op=="-":
            print(a-b)
        if op=="*":
            print(a*b)
        if op=="/":
            print(int(a/b))

Submission status: Accepted

Solution code:
op=0
while op!="?":
    a,op,b=(input().split())
    a=int(a)
    b=int(b)
    if op=="+":
        print(int(a+b))
    elif op=="-":
            print(int(a-b))
    elif op=="*":
        print(int(a*b))
    elif op=="/":
        print(int(a//b))
    else:
        pass

Submission status: Accepted

Solution code:
op = "G"
while op != "?" :
    a,op,b = map(str,input().split())
    if op == "+":
        print(int(a)+int(b))
    elif op == "-":
        print(int(a)-int(b))
    elif op == "*":
        print(int(a)*int(b))
    elif op == "/":
        print(int(int(a)/int(b)))
    else: pass

Submission status: Accepted

Solution code:
while True:
    a,op,b =input().split()
    a=int(a)
    b=int(b)
    if op == "+":
        print(a+b)
    elif op == "-":
        print(a-b)
    elif op == "*":
        print(a*b)
    elif op == "/":
        print(a//b)
    else:
        break

Submission status: Accepted

Solution code:
#ITP1-ITP1_4_C
while True:
  a,op,b = (input().split())
  a = int(a)
  b = int(b)
  if op == "?":
    break
  elif op == "+":
    print(a+b)
  elif op == "-":
    print(a-b)
  elif op == "*":
    print(a*b)
  elif op == "/":
    print(a//b)

Submission status: Accepted

Solution code:
while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)
    
    if op=="+":
        print(a+b)
    elif op=="-":
        print(a-b)
    elif op=="*":
        print(a*b)
    elif op=="/":
        print(a//b)
    elif op=='?':
        break

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()
    a = int(a)
    b = int(b)
    if op == "+":
        print(a + b)
    elif op == "-":
        print(a - b)
    elif op == "*":
        print(a * b)
    elif op == "/":
        print(a // b)
    else:
        break

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()
    a = int(a)
    b = int(b)
    if op == "?":
        break
    elif op == "-":
        s=a-b
        print(s)
    elif op == "*":
        s=a*b
        print(s)
    elif op == "/":
        s=a//b
        print(s)
    elif op == "+":
        s=a+b
        print(s)

Submission status: Accepted

Solution code:
import math
while True:
  a, x, b = input().split()
  a = int(a)
  b = int(b)
  if x == "+":
    print(a+b)
  elif x == "-":
    print(a-b)
  elif x == "/":
    print(math.floor(a/b) )
  elif x == "*":
    print(a*b)
  else:
    break

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()
    a, b = int(a), int(b)
    if op == '?':
        break
    elif op == '+':
        print(a + b)
    elif op == '-':
        print(a -b)
    elif op == '*':
        print(a * b)
    elif op == '/':
        print(a // b)

Submission status: Accepted

Solution code:
while(True):
  a, b, c = map(str, input().split())
  
  if b == "+" :
    print(int(a)+int(c))
  elif b == "-" :
    print(int(a)-int(c))
  elif b == "/" :
    print(int(a)//int(c))
  elif b == "*" :
    print(int(a)*int(c))
  else:
    break

Submission status: Accepted

Solution code:
while True:
    a, b, c = input().split()
    a = int(a)
    c = int(c)
    if b == "?":
        break
    if b == "+":
        print(a + c)
    if b == "-":
        print(a - c)
    if b == "*":
        print(a * c)
    if b == "/":
        print(a // c)

Submission status: Accepted

Solution code:
#２つの整数 a, b と１つの演算子 op を読み込んで、
# a op b を計算するプログラム

while True:
    list = input().split()

    a = int(list[0]); b = int(list[2])
    op = list[1]
    if op == "?":
        break

    if op == "+":
        ans = a + b
    elif op == "-":
        ans = a - b
    elif op == "*":
        ans = a * b
    elif op == "/":
        ans = int(a / b)

    print(ans)

Submission status: Accepted

Solution code:
while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)
    op=str(op)
    
    if op=="+" :
        print(a+b)
    
    elif op=="-":
        print(a-b)
    
    elif op=="*":
        print(a*b)
        
    elif op=="/":
        print(int(a/b))
        
    else:
        break

Submission status: Accepted

Solution code:
while True:
    a,op,b = input().split()
    a = int(a)
    b = int(b)
    if op == "+":
        print(a+b)
    elif op == "-":
        print(a-b)
    elif op == "*":
        print(a*b)
    elif op == "/":
        print(a//b)
    elif op == "?":
        break

Submission status: Accepted

Solution code:
while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)
    if op=='+':
        print(a+b)
    elif op=='-':
        print(a-b)
    elif op=='*':
        print(a*b)
    elif op=='/':
        print(a//b)
    else:
        break

Submission status: Accepted

Solution code:
while True:
	a,b,c = input().split()
	a = int(a)
	c = int(c)
	if b == "?":
		break
	if b == "+":
		print(a + c)
	if b == "-":
		print(a - c)
	if b == "*":
		print(a * c)
	if b == "/":
		print(a // c)

Submission status: Accepted

Solution code:
while True:
  a, op, b = input().split()
  a = int(a)
  b = int(b)
  if op == "+":
    print(a + b)
  elif op == "-":
    print(a - b)
  elif op == "*":
    print(a * b)
  elif op == "/":
    print(a // b)
  else:
    break

Submission status: Accepted

Solution code:
while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)
    if op=="?":
        break
    if op=="+":
        print(a+b)
    if op=="-":
        print(a-b)
    if op=="*":
        print(a*b)
    if op=="/":
        print(a//b)

Submission status: Accepted

Solution code:
while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)
    import math
    if op=="?":
        break
    if op=="+":
        print(math.floor(a+b))
    elif op=="-":
        print(math.floor(a-b))
    elif op=="*":
        print(math.floor(a*b))
    elif op=="/":
        print(math.floor(a/b))

Submission status: Accepted

Solution code:
while True:

    a,op,b = input().split()
    a = int(a)
    b = int(b)

    if op == "+":
        print(a+b)
    elif op == "-":
        print(a-b)
    elif op == "*":
        print(a*b)
    elif op == "/":
        print(int(a/b))
    elif op == "?":
        break

Submission status: Accepted

Solution code:
while True:
    box = [box for box in input().split()]
    box[0] = int(box[0])
    box[2] = int(box[2])
    if box[1] == '?':
        break
    elif box[1] == '+':
        print(box[0] + box[2])
    elif box[1] == '-':
        print(box[0] - box[2])
    elif box[1] == '*':
        print(box[0] * box[2])
    else:
        print(box[0] // box[2])

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()
    if op == '?':
        break
    elif op == '/':
        print(eval(a+'//'+b))
    else:
        print(eval(a+op+b))

Submission status: Accepted

Solution code:
while True:
    a,op,b = input().split()
    if op == "?":
        break
    eval("print(int(int(a) {} int(b)))".format(op))

Submission status: Accepted

Solution code:
while True:
    a,op,b=map(str,input().split())
    if  op=="?":
        break
    else:
        if op=="+":
            print(int(a)+int(b))
        elif op=="-":
            print(int(a)-int(b))
        elif op=="*":
            print(int(a)*int(b))
        else:
            print(int(a)//int(b))

Submission status: Accepted

Solution code:
while True:
    a,op,b = input().split()
    a = int(a)
    b = int(b)
    if op == '?':
        break
    if op == '+':
        print(a+b)
    if op == '-':
        print(a-b)
    if op == '*':
        print(a*b)
    if op == '/':
        print(a//b)

Submission status: Accepted

Solution code:
while True:
  s = input()
  if '?' in s: break
  print(int(eval(s)))

Submission status: Accepted

Solution code:
OP = {'+': lambda a,b: a+b, '-': lambda a,b: a-b, '*': lambda a,b: a*b, '/': lambda a,b: a//b}

while True:
    a, op, b = [s for s in input().split()]
    if op == '?':
        break
    print(OP[op](int(a), int(b)))

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()
    a = int(a)
    b = int(b)
    if op == '?':
        break
    if op == '+':
        print(a + b)
    elif op == '-':
        print(a - b)
    elif op == '*':
        print(a * b)
    elif op == '/':
        print(a // b)

Submission status: Accepted

Solution code:
while True:
    a, op ,b = input().split()
    a = int(a)
    b = int(b)
    if op == "?":
        break
    elif op == "+":
        print(a + b)
    elif op == "-":
        print(a - b)
    elif op == "*":
        print(a * b)
    elif op == "/":
        print(a // b)

Submission status: Accepted

Solution code:
while True:
    a,op,b = input().split()
    a = int(a)
    b = int(b)
    if op == '?':
        break
    if op == '+':
        print(a + b)
    elif op == '-':
        print(a - b)
    elif op == '*':
        print(a * b)
    elif op == '/':
        print(a // b)

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()
    a, b = [int(x) for x in [a, b]]
    
    if op == "+":
        print(f"{a+b}")

    elif op == "-":
        print(f"{a-b}")

    elif op == "*":
        print(f"{a*b}")

    elif op == "/":
        print(f"{a//b}")

    else:
        break

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!

while True:
   a, op, b = input().split()
   a = int(a)
   b = int(b)
   if op == "?": break

   if op == "+":
      print(a + b)
   elif op == "-":
      print(a - b)
   elif op == "*":
      print(a * b)
   else:
      print(int(a / b))

Submission status: Accepted

Solution code:

while True:
    i = input()
    if "?" in i:
        break
    print(int(eval(i)))

Submission status: Accepted

Solution code:
while True:
    a,b,c = input().split()
    a = int(a)
    c = int(c)
    if b == '+':
        print(a + c)
    elif b == '-':
        print(a - c)
    elif b == '*':
        print(a * c)
    elif b == '/':
        print(a // c)
    if b == '?':
        break

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!
import math
while True:
    table=input().split()
    a = int(table[0])
    op = table[1]
    b = int(table[2])

    if op=="?":
        break
    
    if op=="+":
        print(math.floor(a+b))
    elif op == '-':
        print(math.floor(a-b))
    elif op == '/':
        print(math.floor(a/b))
    else:
        print(math.floor(a*b))

Submission status: Accepted

Solution code:
while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)
    
    if op=='?':
        break
    
    if op=='+':
        print(a+b)
    elif op=='-':
        print(a-b)
    elif op=='*':
        print(a*b)
    elif op=='/':
        print(a//b)

Submission status: Accepted

Solution code:
N = input().split()
while True :
    if N[1] == "?" :
        break
    a = int(N[0])
    b = int(N[2])
    if N[1] == "+" :
        print(a+b)
    if N[1] == "-":
        print(a-b)
    if N[1] == "*" :
        print(a*b)
    if N[1] == "/" :
        print(a//b)
    N = input().split()

Submission status: Accepted

Solution code:
import sys

lines = [line.strip().split() for line in sys.stdin.readlines() if line != "\n"]

for line in lines:
    c = int(line[0])
    d = int(line[2])
    op = line[1]

    if op == "+":
        print(c + d)
    elif op == "-":
        print(c - d)
    elif op == "*":
        print(c * d)
    elif op == "/":
        print(c // d)
    else:
        pass

Submission status: Accepted

Solution code:

while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)
    if op=='?' :break
    if op=='+': print(a+b)
    elif op=='-' : print(a-b)
    elif op=='*' : print(a*b)
    elif op=='/' : print(a//b)

Submission status: Accepted

Solution code:
import math
while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)

    if op=="?":break

    if op=="+":
        print(a+b)
    if op=="-":
        print(a-b)
    if op=="*":
        print(a*b)
    if op=="/":
        print(math.floor(a/b))

Submission status: Accepted

Solution code:
while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)
    if op=='?':
        break
    if op=='+':
        print(a+b)
    elif op=='-':
        print(a-b)
    elif op=='*':
        print(a*b)
    elif op=='/':
        print(a//b)

Submission status: Accepted

Solution code:
for x in range(300):
    a, b,c = input().split()
    if b=='?' : break
    a,c=int(a),int(c)
    if b=='+':
        print(a+c)
    elif b=='-' :
        print(a-c)
    elif b=='*':
        print(a*c)
    else :
        print(a//c)

Submission status: Accepted

Solution code:
a,op,b=map(str,input().split())
while op!="?":
    a=int(a)
    b=int(b)
    if op=="+":
        print(a+b)
    elif op=="-":
        print(a-b)
    elif op=="*":
        print(a*b)
    else:
        print(a//b)
    a,op,b=map(str,input().split())    
else:
    pass

Submission status: Accepted

Solution code:
while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)

    if op == '?' :
        break
    if op == '+' :
        print(a+b)
    elif op == '-' :
        print(a-b)
    elif op == '*' :
        print(a*b)
    elif op == '/' :
        print(a//b)

Submission status: Accepted

Solution code:
while True:
    a,op,b = input().split()
    a = int(a)
    b = int(b)
    if op == '+':
        print(a+b)
    elif op == '-':
        print(a-b)
    elif op == '*':
        print(a*b)
    elif op == '/':
        print(int(a/b))
    if op == '?':
        break

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()
    a = int(a)
    b = int(b)
    if op == "+":
        print(a+b)
    elif op == "-":
        print(a-b)
    elif op == "*":
        print(a*b)
    elif op == "/":
        print(int(a/b))
    elif op == "?":
        break

Submission status: Accepted

Solution code:
# coding: utf-8

while True:
    a,op,b = (x for x in input().strip().split())
    a = int(a)
    b = int(b)
    
    if op == "+":
        print(a + b)
    elif op == "-":
        print(a - b)
    elif op == "*":
        print(a * b)
    elif op == "/":
        print(a // b)
    elif op == "?":
        exit()

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()
    if op == "?":
        break
    a = int(a)
    b = int(b)
    if op == "+":
        print(a + b)
    elif op == "-":
        print(a - b)
    elif op == "*":
        print(a * b)
    elif op == "/":
        print(a // b)

Submission status: Accepted

Solution code:
def culc(a, b, op):
    if op == '+':
        return a + b
    elif op == '-':
        return a - b
    elif op == '*':
        return a * b
    else:
        try:
            return a // b
        except:
            return 'error:zerodivision'


while True:
    data = input().split()
    a = int(data[0])
    b = int(data[2])
    if '?' in data:
        break
    print(culc(a, b, data[1]))

Submission status: Accepted

Solution code:
while True :
    table = input().split(" ")
    
    a = int(table[0])
    znsi = table[1]
    b = int(table[2])
    
    if znsi == "?" :
        break
    
    if znsi == "+" :
        print(a + b)
    elif znsi == "-" :
        print(a - b)
    elif znsi == "*" :
        print(a * b)
    else :
        print(a // b)

Submission status: Accepted

Solution code:
result = []
while True:
    a, op, b = input().split()
    a = int(a)
    b = int(b)

    if op == '+':
        result.append(a + b)
    elif op == '-':
        result.append(a - b)
    elif op == '*':
        result.append(a * b)
    elif op == '/':
        result.append(a // b)
    elif op == '?':
        break
for i in result:
    print(i)

Submission status: Accepted

Solution code:
a,op,b=map(str,input().split())
while op!='?':
    a=int(a)
    b=int(b)
    if op=='+':
        print(a+b)
    if op=='-':
        print(a-b)
    if op=='*':
        print(a*b)
    if op=='/':
        print(a//b)
    a,op,b=map(str,input().split())

Submission status: Accepted

Solution code:
while True:
	s = list(input().split())
	s[0] = int(s[0])
	s[2] = int(s[2])
	op = s[1]
	if op == '?':
		exit()
	if op == '+':
		print(s[0]+s[2])
	elif op == '-':
		print(s[0]-s[2])
	elif op == '*':
		print(s[0]*s[2])
	elif op == '/':
		print(s[0]//s[2])

Submission status: Accepted

Solution code:
l = []
i = 0
j = 0
while True:
  l.append(input().split())
  if l[i][1] == '?':
    break
  i += 1

for i in l[:-1]:
  if l[j][1] == '+':
    print(int(l[j][0]) + int(l[j][2]))
  elif l[j][1] == '-':
    print(int(l[j][0]) - int(l[j][2]))
  elif l[j][1] == '*':
    print(int(l[j][0]) * int(l[j][2]))
  elif l[j][1] == '/':
    print(int(l[j][0]) // int(l[j][2]))
  j += 1

Submission status: Accepted

Solution code:
while True:
    table = input().split()

    a = int(table[0])
    op = table[1]
    b = int(table[2])

    if op == '?':
        break

    if op == '+':
        print("%d"%(a+b))
    elif op == '-':
        print("%d"%(a-b))
    elif op == '/':
        print("%d"%(a/b))
    else:
        print("%d"%(a*b))

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()
    a = int(a)
    b = int(b)
    if op == '?':
        break
    if op == '+':
        print(a + b)
    if op == '-':
        print(a - b)
    if op == '*':
        print(a * b)
    if op == '/':
        print(int(a / b))

Submission status: Accepted

Solution code:
while True:
    a,op,b = map(str,input().split())
    a = int(a)
    b = int(b)
    if op == '?':
        break
    elif op == '+':
        print(a + b)
    elif op == '-':
        print(a -b)
    elif op == '/':
        print(a // b)
    elif op == '*':
        print(a * b)

Submission status: Accepted

Solution code:
while True:
    a, op, b=input().split()
    a=int(a)
    b=int(b)
    if op == '+':
        print(a + b)
    if op == '-':
        print(a - b)
    if op == '*':
        print(a * b)
    if op == '/':
        print(a // b)
    if op == '?':
        break

Submission status: Accepted

Solution code:
MAX = 20000
END = '?'
counter = 0
while counter < MAX:
  a, op, b = input().split() 
  if op == END:
    break
  a=int(a)
  b=int(b)
  if op=='+':
    print(a+b)
  elif op=='-':
    print(a-b)
  elif op=='*':
    print(a*b)
  else:
    print(int(a/b))

Submission status: Accepted

Solution code:
for i in range(10000):
    a,b,c = input().split()
    a = int(a)
    c = int(c)
    if b == "/":
        print(a//c)
    elif b == "+" :
        print(a+c)
    elif b == "-":
        print(a-c)
    elif b == "*":
        print(a*c)
    else:
        break

Submission status: Accepted

Solution code:
import sys
from itertools import combinations
import math


def I(): return int(sys.stdin.readline().rstrip())


def LI(): return list(map(int, sys.stdin.readline().rstrip().split()))


def S(): return sys.stdin.readline().rstrip()


def LS(): return list(sys.stdin.readline().rstrip().split())


while 1:
    a = LS()
    if a[1] == '?':
        break
    if a[1] == '+':
        print(int(a[0]) + int(a[2]))
    if a[1] == '-':
        print(int(a[0]) - int(a[2]))
    if a[1] == '*':
        print(int(a[0]) * int(a[2]))
    if a[1] == '/':
        print(int(a[0]) // int(a[2]))

Submission status: Accepted

Solution code:
import sys
import math

for e in sys.stdin:
    a, op, b = e.split()
    a = int(a)
    b = int(b)
    if op == "?":
        break
    elif op == "+":
        print(a + b)
    elif op == "-":
        print(a - b)
    elif op == "*":
        print(a * b)
    else:
        print(math.floor(a / b))

Submission status: Accepted

Solution code:
i=0

while True:
  a, op, b = map(str, input().split())
  a=int(a)
  b=int(b)
  if op=='?':
    break
    
  elif op=='+':
    print(a+b)
  
  elif op=='-':
    print(a-b)
    
  elif op=='*':
    print(a*b)
    
  elif op=='/':
    print(a//b)

Submission status: Accepted

Solution code:
while True:
    a,b,c = input().split()
    a = int(a)
    c = int(c)
    if b == "?":
        break
    elif b == "+":
        print(a + c)
    elif b == "-":
        print(a - c)
    elif b == "*":
        print(a * c)
    elif b == "/":
        print(a // c)

Submission status: Accepted

Solution code:
while True:
    a, op, b = list(map(str, input().split()))
    A = int(a)
    B = int(b)
    if op == "?" :
        break
    if op == "+":
        ans = A + B
    elif op == "-":
        ans = A- B
    elif op == "/":
        ans = A/B
    elif op == "*":
        ans = A*B
    print(int(ans))

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split()
    a = int(a)
    b = int(b)
    if op == '?':
        break
    elif op == '+':
        print(a+b)
    elif op == '-':
        print(a-b)
    elif op == '*':
        print(a*b)
    elif op == '/':
        print(a//b)

Submission status: Accepted

Solution code:
while True:
  a,op,b =input().split()
  a = int(a)
  b = int(b)
  if op=='?':
    break
  ans=0
  if op=='+':
    ans+=(a+b)
  if op=='-':
    ans+=(a-b)
  if op== '*':
    ans+=(a*b)
  if op=='/':
    ans+=(a//b)
  print(ans)

Submission status: Accepted

Solution code:
while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)

    if op=="?":
        break
    else:
        if op=="+":
            print(a+b)
        elif op=="-":
            print(a-b)
        elif op=="*":
            print(a*b)
        elif op=="/":
            print(int(a/b))

Submission status: Accepted

Solution code:
l = []
while True:
  a,op,b = input().split()
  if op == '?':
    break
  l.append((a,op,b))
for t in l:
  na = int(t[0])
  nb = int(t[2])
  op = t[1]
  if op == '+':
    print(na+nb)
  elif op == '-':
    print(na-nb)
  elif op == '*':
    print(na*nb)
  elif op == '/':
    print(na//nb)

Submission status: Accepted

Solution code:
while True:
    a,op,b=(input().split())
    if op=="+":
        print(int(a)+int(b))
    elif op=="-":
        print(int(a)-int(b))
    elif op=="*":
        print(int(a)*int(b))
    elif op=="/":
        print(int(a)//int(b))
    else:
        break

Submission status: Accepted

Solution code:
while True:
    a,op,b=map(str,input().split())
    a=int(a)
    b=int(b)
    if op=="?":
        break
    if op == "+":
        print(a+b)
    elif op == "-":
        print(a-b)
    elif op == "*":
        print(int(a*b))
    elif op == "/":
        print(int(a/b))
    else:
        break

Submission status: Accepted

Solution code:
while True:
  a, operator, b = input().split()
  a, b = int(a), int(b)
  if operator == '?':
    break
  if operator == '+':
    print(a + b)
  if operator == '-':
    print(a - b)
  if operator == '*':
    print(a * b)
  if operator == '/':
    print(a // b)

Submission status: Accepted

Solution code:
a, op, b = input().split()
while op!="?":
    a=int(a)
    b=int(b)
    if op=="+":
        print(a+b)
    elif op=="-":
        print(a-b)
    elif op=="*":
        print(a*b)
    elif op=="/":
        print(int(a/b))
    a, op, b = input().split()

Submission status: Accepted

Solution code:
while True:
     a,op,b=map(str,input().split())
     a=int(a)
     b=int(b)
     0<=a,b<=20000
     if op=='?':
          break
     if op=='+':
          print(a+b)
     if op=='-':
          print(a-b)
     if op=='/':
          print(int(a/b))
     if op=='*':
          print(a*b)

Submission status: Accepted

Solution code:
while True:
    a, o, b=input().split()
    a=int(a)
    b=int(b)
    if o=='?':
        break
    if o=='+':
        print(a+b)
    if o=='-':
        print(a-b)
    if o=='*':
        print(a*b)
    if o=='/':
        print(a//b)

Submission status: Accepted

Solution code:
while True:
    a, op, b = input().split(" ")
    a = int(a)
    b = int(b)
    
    if op == "?":
        break
        
    if op == "+":
        print(a + b)
    elif op == "-":
        print(a - b)
    elif op == "*":
        print(a * b)
    elif op == "/":
        print(a // b)
    else:
        print("Error")

Submission status: Accepted

Solution code:
import sys
a = []
op = []
b = []

for l in sys.stdin:
    aa, opo, bb = l.split()

    if opo == "?":
        break

    a.append(aa)
    op.append(opo)
    b.append(bb)

for i, num in enumerate(a):
    if op[i] == "+":
        print(int(a[i]) + int(b[i]))
    elif op[i] == "-":
        print(int(a[i]) - int(b[i]))
    elif op[i] == "*":
        print(int(a[i]) * int(b[i]))
    elif op[i] == "/":
        print(int(a[i]) // int(b[i]))

Submission status: Accepted

Solution code:
import math
while True:
  a, op, b = input().split()
  a = int(a)
  b = int(b)
  if op == "+":
    print(math.floor(a+b))
  elif op == "-":
    print(math.floor(a-b))
  elif op == "*":
    print(math.floor(a*b))
  elif op == "/":
    print(math.floor(a/b))
  else:
    break

Submission status: Accepted

Solution code:
while True:
    a, op, b = (x for x in input().split())
    a = int(a)
    b = int(b)
    if op == "+":
        ans = a + b
    elif op == "-":
        ans = a - b
    elif op == "*":
        ans = a * b
    elif op == "/":
        ans = a // b
    elif op == "?":
        break
    print(ans)

Submission status: Accepted

Solution code:
while True:
    s = input()
    if "?" in s:
        break
    elif "/" in s:
        s = s.replace("/","//")
    print(eval(s))

Submission status: Accepted

Solution code:
while True:
    a,op,b = input().split(" ")
    a = int(a)
    b = int(b)
    op = str(op)
    if op == "?":
        break
    elif b == 0:
        enzan = {"+":a+b, "-":a-b, "*":a*b}
        print(enzan[op])
    else:
        enzan = {"+":a+b, "-":a-b, "*":a*b, "/":a//b}
        print(enzan[op])

Submission status: Accepted

Solution code:
while True:
    a, op, b =input().split()
    a=int(a)
    b=int(b)
    if op=="+":
        print(a+b)
    elif op=="-":
        print(a-b)
    elif op=="*":
        print(a*b)
    elif op=="/":
        print(a//b)
    elif op=="?":
        break

Submission status: Accepted

Solution code:
import sys

while True:
    a, op, b = input().split()
    if op == '?': break

    a = int(a)
    b = int(b)

    if op == '+': print(a + b)
    if op == '-': print(a - b)
    if op == '*': print(a * b)
    if op == '/': print(a // b)

Submission status: Accepted

Solution code:
while True:
    a,op,b=input().split()
    a=int(a)
    b=int(b)
    if op == '+':
        print(a+b)
    elif op == '-':
        print(a-b)
    elif op == '*':
        print(a*b)
    elif op == '/':
        print(a//b)
    elif op == '?':
        break

Submission status: Accepted

Solution code:
while True:
    a,op,b=input().split()
    if op=="?":
        break
    a=int(a)
    b=int(b)
    if op=="+":
        print(int(a+b))
    elif op=="-":
        print(int(a-b))
    elif op=="*":
        print(int(a*b))
    else:
        print(int(a/b))