import Data.Maybe
main :: IO()
main = do
  inputs <- getContents
  mapM_ (result.calc.(\ ws -> ((read $ head ws ::Int), ws!!1, (read $ ws!!2 ::Int))).words) $ lines inputs

calc :: (Int, String, Int) -> Maybe Int
calc (a, op, b)
    | op == "+" = Just $ a + b
    | op == "-" = Just $ a - b
    | op == "*" = Just $ a * b
    | op == "/" = Just $ a `div` b
    | op == "?" = Nothing

result :: Maybe Int -> IO()
result x | x == Nothing = return ()
         | otherwise = print $ fromJust x