ICPC Is Coming in Hot!

emoncse AUST CSE 44th Batch Pract...
Limits 1s, 512 MB

Tanmoy is an ACM ICPC contestant. During practice he came across a problem named ‘OWLLEN’.

He has having trouble solving this problem so he asked his elder brother for clues. His brother told him that if he wants to solve this problem, he must know how to solve another problem.

Now, Tanmoy needs your help. You need to show him how to solve that problem.

You will be given a large number and you will have to determine which digit in that number has been used the most number of times. If two different digits occur the same number of times print the smallest one.

Input

There will be only one line containing a large number NN (0<N<10100000 < N < 10^{10000}).

Output

You will have to print the digit that has been used the most number of times in that number.

Sample

InputOutput
1213
1

Submit

Login to submit.

Contributors

Statistics

90% Solution Ratio
tahsin_protikEarliest, Apr '19
tahsin_protikFastest, 0.0s
Mushfiq_4513Lightest, 0 B
mdgaziur001Shortest, 35B
Toph uses cookies. By continuing you agree to our Cookie Policy.