Deducing relationships | 프로그래밍의 벗 PivotOJ
PivotOJ

Deducing relationships

시간 제한: 1000ms메모리 제한: 1024MB출처: EIO 2019-20 openBOJ 29912

문제

Let's consider equalities and inequalities between the numbers aa, bb, and cc. The relationships between the numbers can be expressed as a 3×33 \times 3 table, with two characters for each pair (x,y)(x, y) denoting their relationship as '<<', '', '==', '>=', '>>' (x<yx < y, xyx \le y, x=yx = y, xyx \ge y, x>yx > y, respectively), or '??' (if the relationship is not known and can't be deduced from the known ones).

The input contains two known equalities or inequalities and the program must fill the table with the strongest relationships that can be deduced from the input. This means that if it is possible to deduce that x<yx < y then the program must output '<<' in the corresponding cell of the table, and not '', even though xyx \le y also holds.

입력

The two lines of input each contain one relationship (equality or inequality).

출력

The output should contain exactly three lines of the table, where each cell of the table contains the strongest possible relationship that can be deduced, with the cells on each line spearated by spaces, or the message 'VASTUOLU', denoting a contradiction in the input.

예제

예제 1

입력
a<=b
b<<c
출력
== <= <<
>= == <<
>> >> ==

예제 2

입력
a<<b
b<=a
출력
VASTUOLU
코드를 제출하려면 로그인하세요.