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: Wrong Answer

Solution code:
import sys


def main():
    while True:
        list1 = [i for i in sys.stdin.readline().split()]
        if '?' in list1:
            break
        a, b, op = int(list1[0]), int(list1[2]), list1[1]
        if op == '+':
            print(a + b)
        elif op == '-':
            print(a - b)
        elif op == '*':
            print(a * b)
        else:
            print(a / b)
    return


if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
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(a) // int(b))
else:
    exit()

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
while True:
    s = input()
    try:
        print(eval(s))
    except:
        break

Submission status: Wrong Answer

Solution code:
inputs = input().split(' ')
a = int(inputs[0])
op = inputs[1]
b = int(inputs[2])
if op == "+":  # (和)
    print(a + b)
elif op == "-":  # (差)
    print(a - b)
elif op == "*":  #(積)
    print(a * b)
else:  # "/"(商)
    print(a // b)

Submission status: Wrong Answer

Solution code:
inputs = input().split(' ')
a = int(inputs[0])
op = inputs[1]
b = int(inputs[2])
if op == "?":
    pass
elif op == "+":  # (和)
    print(a + b)
elif op == "-":  # (差)
    print(a - b)
elif op == "*":  #(積)
    print(a * b)
else:  # "/"(商)
    print(a // b)

Submission status: Wrong Answer

Solution code:
while 1:
    n = input()

    if "?" in n:
        break
    print(eval(n))

Submission status: Wrong Answer

Solution code:
while 1:
    n = input()

    if "?" in n:
        break
    print(eval(n))

Submission status: Wrong Answer

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: Wrong Answer

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: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
while True:
    a, b, c = map(str, 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: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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: Wrong Answer

Solution code:
import sys,math

def solve():
    while True:
        s = input()
        if s == "0 ? 0":
            break
        else:
            print(eval(s))
    
solve()

Submission status: Wrong Answer

Solution code:
a = input()
while not "?" in a:
    print(eval(a))
    a = input()

Submission status: Wrong Answer

Solution code:

for i in range(1000):
    
    a, b, c = input().split()
    
    if b == '?': break
    
    a = int(a)
    c = int(c)
    
    print(a, b, c)

Submission status: Wrong Answer

Solution code:

for i in range(1000):
    
    a, b, c = input().split()
    
    if b == '?': break
    
    a = int(a)
    c = int(c)
    
    if b == '+': print(a + c)
    if b == '-': print(a - c)
    if b == '*': print(a * c)
    if b == '/': print(a / c)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
while(1):
    a = input()
    if a == "0 ? 0":
        break
    eval("print("+a+")")

Submission status: Wrong Answer

Solution code:
while(1):
    a = input()
    if a.split()[1] == "?":
        break
    eval("print("+a+")")

Submission status: Wrong Answer

Solution code:
'''
a,op,b = input().split()

a,b = int(a),int(b)
'''
###############################################################
#whileの中に入れないと同じデータセットでの計算をずっとし続ける#
###############################################################

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: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
34.1201

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
while True:
  a,op,b = input().split()
  if op == "?":
    break
  elif 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: Wrong Answer

Solution code:
x = input().split()
a = int(x[0])
op = x[1]
b = int(x[2])
for i in range(1):
  if op == "+":
    A = a + b
    print(A)
  elif op == "-":
    B = a - b
    print(B)
  elif op == "*":
    C = a * b
    print(C)
  elif op == "/":
    D = a // b
    print(D)
  elif op == "?":
    break

Submission status: Wrong Answer

Solution code:
s=input().split()
a,b=map(int,(s[0],s[2]))
op=s[1]
if op=="+":
    print(a + b)
elif op=="-":
    print(a - b)
elif op=="*":
    print(a * b)
elif op=="/":
    print(a / b)

Submission status: Wrong Answer

Solution code:
numbers = [1,2,3,4,5]

for n in numbers:
    print(n)

Submission status: Wrong Answer

Solution code:
while(True):
    f = input()
    s = f.split()
    if s[1] == '?':
        break
    print(eval(f))

Submission status: Wrong Answer

Solution code:
a=input()
while a!="0 ? 0":
    print(eval(a))
    a=input()

Submission status: Wrong Answer

Solution code:
a=input()
while a[2]!="?":
    print(eval(a))
    a=input()

Submission status: Wrong Answer

Solution code:
for i in range(10000):
    try:
        a = eval(input())
        print(a)
    except:
        break

Submission status: Wrong Answer

Solution code:
listA=[]
listOP=[]
listB=[]
count=0
while True:
    a,op,b=input().split()
    listA.append(int(a))
    listOP.append(op)
    listB.append(int(b))
    if a=="0" and op=="?" and b=="0":
        del listA[len(listA)-1]
        del listOP[len(listOP)-1]
        del listB[len(listB)-1]
        break
#入力パートここまで。計算出力パートここから
while count<=len(listA)-1:
    if listOP[count]=="+":
        print(listA[count]+listB[count])
    elif listOP[count]=="-":
        print(listA[count]-listB[count])
    elif listOP[count]=="*":
        print(listA[count]*listB[count])
    elif listOP[count]=="/":
        print(listA[count]/listB[count])
    else:
        print("ERROR")
    count+=1

Submission status: Wrong Answer

Solution code:
a_list = [str(x) for x in input().split()]
a = int(a_list[0])
b = int(a_list[2])
op = a_list[1]
if op == '+':
    ab = a + b
    print(ab)
elif op == '-':
    ab = a - b
    print(ab)
elif op == '*':
    ab = a * b
    print(ab)
elif op == '/':
    ab = a // b
    print(ab)
elif op == '-':
    exit()

Submission status: Wrong Answer

Solution code:
while True:
    s=input().split()
    a=s[0]
    op=s[1]
    b=s[2]
    if not (op=="+" or op=="-" or op=="*" or op=="/"):
        break
    if op=="+":
        print(a + b)
    elif op=="-":
        print(a - b)
    elif op=="*":
        print(a * b)
    elif op=="/":
        print(a / b)

Submission status: Wrong Answer

Solution code:
while True:
    s=input().split()
    op=s[1]
    if not (op=="+" or op=="-" or op=="*" or op=="/"):
        break
    a=int(s[0])
    b=int(s[2])
    if op=="+":
        print(a + b)
    elif op=="-":
        print(a - b)
    elif op=="*":
        print(a * b)
    elif op=="/":
        print(a / b)

Submission status: Wrong Answer

Solution code:
line = input().split()
a = int(line[0])
op = line[1]
b = int(line[2])

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

Submission status: Wrong Answer

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 a=="?" or b=="?" or op=="?":
        break

Submission status: Wrong Answer

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/float(b))
    elif a=="?" or b=="?" or op=="?":
        break

Submission status: Wrong Answer

Solution code:
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=='?':
  pass

Submission status: Wrong Answer

Solution code:
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:
  pass

Submission status: Wrong Answer

Solution code:
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:
  pass

Submission status: Wrong Answer

Solution code:
ops = []
kekka = []

while True:
    op = [e for e in input().split()]
    if op[1]=="?":
        break
    ops.append(op)

for i in range(len(ops)):
    if ops[i][1]=="+":
        sum = int(ops[i][0]) + int(ops[i][2])
        kekka.append(sum)
    elif ops[i][1]=="-":
        hiku = int(ops[i][0]) - int(ops[i][2])
        kekka.append(hiku)
    elif ops[i][1]=="*":
        kakeru = int(ops[i][0]) * int(ops[i][2])
        kekka.append(kakeru)
    elif ops[i][1]=="/":
        waru = "{:.0f}".format(int(ops[i][0]) / int(ops[i][2]))
        kekka.append(waru)

print(" ".join(map(str, kekka)))

Submission status: Wrong Answer

Solution code:
ops = []
kekka = []

while True:
    op = [e for e in input().split()]
    if op[1]=="?":
        break
    ops.append(op)

for i in range(len(ops)):
    if ops[i][1]=="+":
        sum = int(ops[i][0]) + int(ops[i][2])
        kekka.append(sum)
    elif ops[i][1]=="-":
        hiku = int(ops[i][0]) - int(ops[i][2])
        kekka.append(hiku)
    elif ops[i][1]=="*":
        kakeru = int(ops[i][0]) * int(ops[i][2])
        kekka.append(kakeru)
    elif ops[i][1]=="/":
        waru = "{:.0f}".format(int(ops[i][0]) / int(ops[i][2]))
        kekka.append(waru)

for j in kekka:
    print(j)

Submission status: Wrong Answer

Solution code:
ops = []
kekka = []

while True:
    op = [e for e in input().split()]
    if op[1]=="?":
        break
    ops.append(op)

for i in range(len(ops)):
    if ops[i][1]=="+":
        sum = int(ops[i][0]) + int(ops[i][2])
        kekka.append(sum)
    elif ops[i][1]=="-":
        hiku = int(ops[i][0]) - int(ops[i][2])
        kekka.append(hiku)
    elif ops[i][1]=="*":
        kakeru = int(ops[i][0]) * int(ops[i][2])
        kekka.append(kakeru)
    elif ops[i][1]=="/":
        waru = "{:.0f}".format(int(ops[i][0]) / int(ops[i][2]))
        kekka.append(waru)

for j in kekka:
    print(int(j))

Submission status: Wrong Answer

Solution code:
ops = []
kekka = []

while True:
    op = [e for e in input().split()]
    if op[1]=="?":
        break
    ops.append(op)

for i in range(len(ops)):
    if ops[i][1]=="+":
        sum = int(ops[i][0]) + int(ops[i][2])
        kekka.append(sum)
    elif ops[i][1]=="-":
        hiku = int(ops[i][0]) - int(ops[i][2])
        kekka.append(hiku)
    elif ops[i][1]=="*":
        kakeru = int(ops[i][0]) * int(ops[i][2])
        kekka.append(kakeru)
    elif ops[i][1]=="/":
        waru = round(int(ops[i][0]) / int(ops[i][2]))
        kekka.append(waru)

for j in kekka:
    print(int(j))

Submission status: Wrong Answer

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))
    elif(op == '?'):
        break;

Submission status: Wrong Answer

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

 if op == '?':
  break
 if op == '+':
  ans = a + b
 if op == '-':
  ans = a-b
 if op == '*':
  ans = a*b
 if op == '/':
  ans = a/b

 print(ans)

Submission status: Wrong Answer

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

 if op == '?':
  break
 if op == '+':
  ans = a+b
 if op == '-':
  ans = a-b
 if op == '*':
  ans = a*b
 if op == '/':
  ans = a/b

 print(ans)

Submission status: Wrong Answer

Solution code:
while True:
 a, op, b = 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
 else:
  ans = a/b

 print(ans)

Submission status: Wrong Answer

Solution code:
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))

Submission status: Wrong Answer

Solution code:
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) / float(b))

Submission status: Wrong Answer

Solution code:
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(float(a) / float(b))

Submission status: Wrong Answer

Solution code:
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) * 1.0 / float(b))

Submission status: Wrong Answer

Solution code:
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('/')
    print(int(a) / float(b))

Submission status: Wrong Answer

Solution code:
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) / float(b))

Submission status: Wrong Answer

Solution code:
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(0.5)

Submission status: Wrong Answer

Solution code:
a, op, b = input().split()
print(a)
print(op)
print(b)

Submission status: Wrong Answer

Solution code:
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))

Submission status: Wrong Answer

Solution code:
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('/')
    print(int(a) // int(b))

Submission status: Wrong Answer

Solution code:
while(True):
    print('input:')
    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: Wrong Answer

Solution code:
ans = 0
while True:
    num = list(map(str,input().split()))
    if(num[1] == "?"): break
    a = int(num[0])
    b = int(num[2])
    if(num[1] == "+"): ans=a+b
    elif(num[1] == "-"): ans=a-b
    elif(num[1] == "*"): ans=a*b
    else: ans=a/b
    print(ans)

Submission status: Wrong Answer

Solution code:
ans = 0
while True:
    num = list(map(str,input().split()))
    if(num[1] == "?"): break
    a = int(num[0])
    b = int(num[2])
    if(num[1] == "+"): ans=a+b
    elif(num[1] == "-"): ans=a-b
    elif(num[1] == "*"): ans=a*b
    elif(num[1] == "/"):ans=a/b
    else: break
    print(ans)

Submission status: Wrong Answer

Solution code:
ans = 0
while True:
    num = list(map(str,input().split()))
    if(num[1] == "?"): break
    a = int(num[0])
    b = int(num[2])
    if(num[1] == "+"): ans=a+b
    elif(num[1] == "-"): ans=a-b
    elif(num[1] == "*"): ans=a*b
    elif(num[1] == "/"):ans=a/b
    
    print(ans)

Submission status: Wrong Answer

Solution code:
ans = 0
while True:
    num = list(map(str,input().split()))
    if(num[1] == "?"): break
    a = int(num[0])
    b = int(num[2])
    op = num[1]
    if(op == "+"): ans=a+b
    elif(op == "-"): ans=a-b
    elif(op == "*"): ans=a*b
    elif(op == "/"): ans=a/b
    
    print(ans)

Submission status: Wrong Answer

Solution code:
while True:
    a=input()

    if '?' in a:
        break

    eval('print({0})'.format(a))

Submission status: Wrong Answer

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)
  if op == '-':
    print(a*b)
  if op == '*':
    print(a//b)

Submission status: Wrong Answer

Solution code:
while True:
    a = input()
    if "?" in a:
        break
    print(eval(a))

Submission status: Wrong Answer

Solution code:
import sys, operator

list = {'+':operator.add, '-':operator.sub, '*':operator.mul, '/':operator.truediv}

for line in sys.stdin:
    a, op, b = line.split()
    if op == '?': break
    print(int(list[op](a, b)))

Submission status: Wrong Answer

Solution code:
a, op, b = map(str, raw_input().split())
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

Submission status: Wrong Answer

Solution code:
a, op, b = map(str, raw_input().split())
a = int(a)
b = int(b)

if op == "+":
	print a + b
elif op == "-":
	print a - b
elif op == "*":
	print a * b
else:
	if b == 0:
		print 0
	else:
		print a / b

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
a_list = []
b_list = []
op_list = []
count = 0
while True:
  a, op, b = (str(i) for i in input().split())
  if op != '?':
    a_list.append(int(a))
    b_list.append(int(b))
    op_list.append(op)
    count += 1
  else:
    break
for i in range(0,count):
  if op_list[i] == '+':
    print(a_list[i] + b_list[i])
  elif op_list[i] == '-':
    print(a_list[i] - b_list[i])
  elif op_list[i] == '*':
    print(a_list[i] * b_list[i])
  elif op_list[i] == '/' and a_list[i] % b_list[i] == 0:
    print(a_list[i] // b_list[i])
  else:
    print(a_list[i] % b_list[i])

Submission status: Wrong Answer

Solution code:
a_list = []
b_list = []
op_list = []
count = 0
while True:
  a, op, b = (str(i) for i in input().split())
  if op != '?':
    a_list.append(int(a))
    b_list.append(int(b))
    op_list.append(op)
    count += 1
  else :
    break
for i in range(0,count):
  if op_list[i] == '+':
    print(a_list[i] + b_list[i])
  elif op_list[i] == '-':
    print(a_list[i] - b_list[i])
  elif op_list[i] == '*':
    print(a_list[i] * b_list[i])
  elif op_list[i] == '/' and a_list[i] % b_list[i] == 0:
    print(a_list[i] // b_list[i])
  else:
    print(float(a_list[i] / b_list[i]))

Submission status: Wrong Answer

Solution code:
#!/usr/bin/env python
# -*- coding: utf-8 -*-

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)
    else:
        print(a / b)

Submission status: Wrong Answer

Solution code:
while True:
	a=raw_input()
	if a == "0 ? 0":
		break
	b=a.split()
	for i,c in enumerate(b):
		if i==0:
			x=c
		elif i==1:
			y=c
		else:
			z=c
	if y=='+':
		w=x+z
	elif i=='-':
		w=x-z
	elif i=='*':
		w=x*z
	else:
		w=int(x)/int(z)
	print w

Submission status: Wrong Answer

Solution code:
#coding:UTF-8

a,op,b = map(str,raw_input().split())
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

Submission status: Wrong Answer

Solution code:
#coding:UTF-8

a,op,b = map(str,raw_input().split())
a = int(a)
b = int(b)

while True:
    if op == '+':
        print a + b        
        break
    elif op == '-':
        print a - b
        break
    elif op == '*':
        print a * b
        break 
    elif op == '/':
        print a / b
        break
    else:
        print a + b
        break

Submission status: Wrong Answer

Solution code:
#coding:UTF-8

a,op,b = map(str,raw_input().split())
a = int(a)
b = int(b)

while True:
    if op == '+':
        print a + b        
        break
    elif op == '-':
        print a - b
        break
    elif op == '*':
        print a * b
        break 
    elif op == '/':
        print a / b
        break
    else:
        break

Submission status: Wrong Answer

Solution code:
def main():
    flag = True
    while flag:
        s1, tr, s2 = input().split()
        s1, s2 = int(s1), int(s2)
        if tr == "+":
            print(s1 + s2)
        elif tr == "-":
            print(s1 - s2)
        elif tr == "*":
            print(s1 * s2)
        elif tr == "/":
            print(s1 / s2)
        else:
            flag = False
            break


if __name__=="__main__":
    main()

Submission status: Wrong Answer

Solution code:
def cal(a, op, b):

  if op == '+':
    r = a + b
  elif op == '-':
    r = a + b
  elif op == '*':
    r = a * b
  else:
    r = a / b
  return r

while 1:
  a,op,b = raw_input().split()
  if op == '?':
    break
  else:
    print(cal(int(a), op, int(b)))

Submission status: Wrong Answer

Solution code:
while 1:
    t = input()
    if t == '0 ? 0':
        break
    print(eval(t))

Submission status: Wrong Answer

Solution code:
while True:
    (a, op, b) = input().split()
    a = int(a)
    b = int(b)
    b = b > a
    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: Wrong Answer

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

    if op == '?':
        break

    if op == '+':
        print(a + b)

    if op == '-':
        print(a - b)

    if op == '*':
        i = a * b
        print(a * b)

    if op == '/':
        print(a // b)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
import re
while True:
    s = input()
    if (re.match(r'.+\s\?\s.+', s)):
        break
    print(eval(s))

Submission status: Wrong Answer

Solution code:
while True:
 x = raw_input().split()
 a = x[0]
 b = x[2]
 op = x[1]
 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: Wrong Answer

Solution code:

while True:
    entry = map(str, raw_input().split())
    a  = entry[0]
    op = entry[1]
    b  = entry[2]
    if op == "?":
        break
    elif op == "+":
        ans = a + b
    elif op == "-":
        ans = a - b
    elif op == "*":
        ans = a * b
    elif op == "/":
        ans = a / b
    print(ans)

Submission status: Wrong Answer

Solution code:
str = raw_input().split()
a = int(str[0])
op = str[1]
b = int(str[2])

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

Submission status: Wrong Answer

Solution code:
while(True):
    (a,op,b) = [s for s in 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: Wrong Answer

Solution code:
while 1:
  input_a , op , input_b = raw_input().split()
  a = int( input_a )
  b = int( input_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: Wrong Answer

Solution code:
while 1:
  input_a , op , input_b = raw_input().split()
  a = int( input_a )
  b = int( input_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: Wrong Answer

Solution code:
while 1:
  input_a , op , input_b = map( str , raw_input().split() )
  a = int( input_a )
  b = int( input_b )

  if op == '+':
    print a + b
  elif op == '-':
    print a - b
  elif op == '*':
    print a + b
  elif op == '/':
    print a + b
  else:
    break