Identify the correct output of the Python code: L1=[1,2,3] L2=[4,5] L3=[6,7]…

PYQ KVS TGT/PGT 2023

Identify the correct output of the Python code: L1=[1,2,3] L2=[4,5] L3=[6,7] L1.extend(L2) L1.append(L3) print(L1)

  1. A.

    [1, 2, 3, 4, 5, 6, 7]

  2. B.

    [1, 2, 3, [4, 5], 6, 7]

  3. C.

    [1, 2, 3, 4, 5, [6, 7]]

  4. D.

    [1, 2, 3, [4, 5], [6, 7]]

Attempted by 2281 students.

Sign up free to check your answer

Sign up free

Explore the full course: Kvs Nvs Tier 2 Computer Science

Loading lesson…