Toggle navigation
Home
Problems
Status
Ranklist
Contests
OSC
FAQ
[Sign In]
[Sign Up]
计算a+aa+aaa+…之和-循环[易]
Time Limit
1s
Memory Limit
131072KB
Judge Program
Standard
Ratio(Solve/Submit)
62.72%(
710
/
1132
)
Description:
输入两个正整数
a
和
n
,输出
a+aa+aaa+…+
a
…
a
(
n
个
a
)之和。例如,输入
2
和
3
,输出
246
(
2+22+222
)。
Input:
2
3
Output:
246
Sample Input:
3 4
Sample Output:
3702
Source:
cxliu
Submit
Compiler
C
C++
Java
Python2
Python3
Use advanced editor
Code