diff --git a/Algo/B2/Exercises/Repetitive tutorial.md b/Algo/B2/Exercises/Repetitive tutorial.md index c0e3037..9726c07 100644 --- a/Algo/B2/Exercises/Repetitive tutorial.md +++ b/Algo/B2/Exercises/Repetitive tutorial.md @@ -48,5 +48,9 @@ def productZ(x, y): ## Exercise 1.3 ``` -def exponentiation(x: int, n: int) -> int: - \ No newline at end of file +def exponetial(x: int, n: int) -> int: + result = 0 + while n > 0: + m *= x + n -= 1 + return result \ No newline at end of file