题目描述
Problem Statement
Let xyz denote the 3-digit integer whose digits are x, y, z from left to right.
Given a 3-digit integer abc none of whose digits is 0, find abc+bca+cab.
Input
Input is given from Standard Input in the following format:
abc
Output
Print the answer.
Constraints
- abc is a 3-digit integer abc none of whose digits is 0.
Sample Input 1
123
Sample Output 1
666
We have 123+231+312=666.
Sample Input 2
999
Sample Output 2
2997
We have 999+999+999=2997.
输入格式
见题面 Input 部分
输出格式
见题面 Output 部分
样例输入
123
样例输出
666