What will be the output of the following Python code? a = (1,2,3,4,5)…

PYQ IBPS SO CRP SPL-XIV (2024)

What will be the output of the following Python code?

a = (1,2,3,4,5)

print(a[-4:-1])

  1. A.

    (2, 3, 4)

  2. B.

    (3, 4, 5)

  3. C.

    (2, 3, 4, 5)

  4. D.

    (1, 2, 3)

  5. E.

    (3, 4)

Attempted by 135 students.

Sign up free to check your answer

Sign up free

Explore the full course: Ibps So It Mains

Loading lesson…