def mul(a):
if a<2:
return a
return mul(a-1)*a
while True:
try:
s = input().split()
if len(s) == 3:
a = int(s[0])
b = int(s[2])
if s[1] == '+':
res = a+b
if s[1] == '-':
res = a-b
if s[1] == '*':
res = a*b
if s[1] == '/':
if b==0:
res="error"
else:
res = a/b
if s[1] == '%':
if b==0:
res="error"
else:
res = a%b
else:
a = int(s[0])
if s[1] == '!':
res = mul(a)
print(int(res))
except:
break

京公网安备 11010502036488号