
| Contests | Virtual Contests | Problems | Submit | Runs Status | Rank List | Forum |
The numerical bases that may appear vary from 1 to 9. Remember that a number expressed in base b uses only digits less than b.
Your task is to develop a program that simulates the function of the comparator component.
The input contains several test cases, each one of them in a separate line. Each test case has four numerical strings, each two of them separated by a blank character, say
s b t c
Strings b and c are one-character strings. They represent the bases for the first and third strings s and t, respectively.
The end of the input is denoted by the end of file.
Output text for each input case is presented in the same order that input is read. For each test case the answer must be a left aligned answer-character corresponding to the input. This character must be < , = or > , accordingly to the fact that the first string represents a numerical value less than, equal to or greater that the represented by the third string.
54 6 71 8 110 2 6 7 3 4 3 9 14 7 1000 2
< = = >