Logo
(追記) (追記ここまで)

29912번 - Deducing relationships 다국어

시간 제한메모리 제한제출정답맞힌 사람정답 비율
1 초 1024 MB53360.000%

문제

Let's consider equalities and inequalities between the numbers $a,ドル $b,ドル and $c$. The relationships between the numbers can be expressed as a 3ドル \times 3$ table, with two characters for each pair $(x, y)$ denoting their relationship as '<<', '', '==', '>=', '>>' ($x < y,ドル $x \le y,ドル $x = y,ドル $x \ge y,ドル $x > 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 < y$ then the program must output '<<' in the corresponding cell of the table, and not '', even though $x \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

예제 출력 1

== <= <<
>= == <<
>> >> ==

If $a \le b$ and $b < c,ドル as given in the input, then also $a < c$. If $a \le b,ドル then $b \ge a$; if $b < c,ドル then $c > b$; if $a < c,ドル then $c > a$. In any case $a = a,ドル $b = b,ドル and $c = c$. Writing all these results in the table, we get the given output.

예제 입력 2

a<<b
b<=a

예제 출력 2

VASTUOLU

It's not possible that $a < b$ and at the same time $b \le a$ (or $a \ge b$).

힌트

출처

Olympiad > Estonian Informatics Olympiad > 2019-20 > Open Competition 2번

(追記) (追記ここまで)

출처

대학교 대회

  • 사업자 등록 번호: 541-88-00682
  • 대표자명: 최백준
  • 주소: 서울시 서초구 서초대로74길 29 서초파라곤 412호
  • 전화번호: 02-521-0487 (이메일로 연락 주세요)
  • 이메일: contacts@startlink.io
  • 통신판매신고번호: 제 2017-서울서초-2193 호

AltStyle によって変換されたページ (->オリジナル) /