A program that scan a number n and then output the sum of the powers from 1 to n. Thus, if the input is 4, the output should be 288:
1¹ + 2² + 3³ + 4^4 1 + 4 + 27 + 256 = 288
Solution: for loop, while loop, do while loop
Please fix the following input errors: