COCI '07 Contest 5 #1 Tri

View as PDF

Submit solution


Points: 3
Time limit: 1.0s
Memory limit: 32M

Problem types

Little Mirko wrote into his math notebook an equation containing three positive integers, the equals sign and one of the four basic arithmetic operations (addition, subtraction, multiplication and division).

During another class, his friend Slavko erased the equals sign and the operations from Mirko's notebook.

Help Mirko by reconstructing the equation from the three integers.

Input Specification

The first line of input contains three integers less than 100, separated by spaces.

Note: The input data will guarantee that a solution, although not necessarily unique, will always exist.

Output Specification

On a single line, output a valid equation containing the three integers (in the same order), an equals sign and one of the four operations. If there are multiple solutions, output any of them.

Sample Input 1

5 3 8

Sample Output 1

5+3=8

Sample Input 2

5 15 3

Sample Output 2

5=15/3

Comments


  • -2
    ZEN  commented on Dec. 27, 2017, 4:52 a.m.

    "output any of them" meaning any one or all?


    • -2
      jkguipqnjcy49979693  commented on Dec. 27, 2017, 4:57 a.m.

      any one


      • -2
        ZEN  commented on Dec. 27, 2017, 5:09 a.m.

        thanks had to submit a few times to figure out lol