Problem list
Log in
#coci00121 · COCI 2009/2010 Contest 3

Filip

Bronze II 1.0 s 32 MB

Mirko has a younger brother, Filip, who just started going to school and is having trouble with numbers. To help him get the hang for number scale, his teacher writes two three digit numbers. She asks Filip to compare those numbers, but instead of interpreting them with the leftmost most significant digit, he needs to interpret them the other way around, with the most significant digit being the rightmost one. He than has to tell the teacher the larger of the two numbers. Write a program that will check Filips answers.

Input

The first and only line of input contains two three digit numbers, $A$ and $B$. $A$ and $B$ will not be equal and will not contain any zeroes.

Output

First and only line of output should contain the larger of the numbers in the input, compared as described in the task. The number should be written reversed, to display to Filip how he should read it.

Example 1

Input
734 893
Output
437

Example 2

Input
221 231
Output
132

Example 3

Input
839 237
Output
938
Source
COCI 2009/2010 Contest 3
Appears in
Not part of a ladder, contest or set yet.
Accepted 0 Submissions 0 Acceptance 0% Solvers 0

Discussion

Threads about this problem. Spoilers are collapsed; wrap hints in ||double bars||.

No discussion yet. Start a thread if something here needs explaining.

Recent submissions Open with filters
Code