-->
当前位置:首页 > 题库

PROGRAMMING:Sum of powers

Luz5年前 (2021-05-10)题库410
This problem requires the preparation of procedures to calculate $$sum = 2 ^ 1 + 2 ^ 2 + 2 ^ 3 + - cdots + 2 ^ n $$. The pow function can be called for exponentiation.
###Input format:
Input gives a positive integer $$n $$($$Le $$10) on one line.
###Output format:
Output according to the format "result = calculation result".
###Input example:
```in
five
```
###Output example:
```out
result = 62
```






answer:If there is no answer, please comment