Linear inequality
Easy
Execution time limit is 1 second
Runtime memory usage limit is 64 megabytes
Solve the linear inequality ax + b > (≥, <, ≤) 0.
Input
The first line contains the inequality sign, which is one of the four possible options. The second line provides the coefficients of the inequality, where all numbers are integers and do not exceed 1000 in absolute value, with a ≠ 0.
Output
Present the solution of the inequality as an interval. All numbers in the solution should be integers. Do not include spaces between symbols. If the interval includes infinity, represent it with the English letter i (from the word infinity) along with the appropriate sign.
Examples
Input #1
Answer #1
Submissions 577
Acceptance rate 18%