Carol is buying water for her Cactus. However her Cactus has a problem - he simply does not understand how much water is too much water. However, it is essential that she keep water away from her Cactus, for the Cactus will go seek out more water and then die of water overdose.
Thus, Carol needs a way to calculate the perfect amount of water required to quench her Cactus' thirst.
She gives you
A cute number is a number that is palindromic. e.g.
Constraints
Input Specification
The first line will contain
Output Specification
The amount of water that Carol should purchase for her Cactus. The input data are set such that Carol will be able to purchase water for her Cactus.
Sample Input 1
1000 5000
Sample Output 1
3003
Sample Input 2
234 2343
Sample Output 2
1331
Comments