import Control.Applicative
import Data.List

main = do 
	xs <- map words . takeWhile (not . isInfixOf "?") . lines <$> getContents
	mapM (putStrLn . show . calclator) xs


calclator :: [String] -> Integer
calclator (a:op:b:_) = case op of
	"+"	-> n + m
	"-" -> n - m
	"*" -> n * m
	"/" -> n `div` m
	where
		n = read a :: Integer
		m = read b :: Integer

