The math of exponent expressions

why would this give me an error?

print(6 ** 2 * 6)

is the same as the expected result

print(6 ** 4)

Hello, @mussussu!

6**2 = 36
36 * 6 = 216

6**4 = 1,296

1 Like

and @mussussu what @midlindner says makes sense. In your statement, you basically wrote

print(6**3)

which does not equal 6**4. Now, if you had done print(6**2*6*6), you would have been correct because that is equivalent to saying 6**4.

Sorry to interject but I think that’s what you were trying to get there

1 Like
x ** a * x ** b == x ** (a + b)    

x ** a / x ** b == x ** (a - b)

https://sciencing.com/10-laws-exponents-7273644.html

1 Like