M

Mr. Dubey • 52.61K Points
Coach

Q. The expression 2**2**3 is evaluates as: (2**2)**3.

(A) true
(B) false
(C) ---
(D) ---
Share

Explanation by: Mr. Dubey
 the value of the expression (2**2)**3 = 4**3 = 64. when the expression 2**2**3 is evaluated in python, we get the result as 256, because this expression is evaluated as 2**(2**3). this is because the associativity of exponentiation operator (**) is from right to left and not from left to right.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.


Question analytics