What will be the output of the following Python function? print(2**3**2,…

2026

What will be the output of the following Python function?

print(2**3**2, (2**3)**2, 2**(3*2))

  1. A.

    512 64 64

  2. B.

    512 512 512

  3. C.

    64 64 64

  4. D.

    64 64 512

Attempted by 191 students.

Show answer & explanation

Correct answer: A

2**3**2 = 512 (right-associative). (2**3)**2 = 64. 2**(3*2) = 64.

Explore the full course: Rssb Senior Computer Instructor