|
|||
Arithmetic Operations #2Write a program that reads integers and operators of the C programming language from the standard input line by line, performs the operation indicated by the operator on the scanned/read values and writes the result to the standard output. Input Specification
Each of the input lines contains a test case until end-of-file (EOF).
Each test case is a line in the form „x op y” where x
and y are integers, while op is one of the following integer arithmetic operators
of the C programming language: Output SpecificationFor each test case, the program must write a single line containing the result of the operation x op y specified in the test case. Sample Input
Output for Sample Input
Acknowledgement
This work was supported by the construction EFOP-3.4.3-16-2016-00021. The project was supported by the European Union, co-financed by the European Social Fund.
|
|||
University of Debrecen; Faculty of Informatics; v. 09/30/2024 |