计算a+aa+aaa+…之和-循环[易]

Time Limit
1s
Memory Limit
131072KB
Judge Program
Standard
Ratio(Solve/Submit)
62.72%(710/1132)
Description:

输入两个正整数an,输出a+aa+aaa+…+aana)之和。例如,输入23,输出2462+22+222)。

Input:

2  3

Output:

246

Sample Input:
3  4
Sample Output:
3702
Source:

cxliu


Submit