QuestionQ117

VerifiedData Collections – Tuples, Dictionaries, Lists, and Strings

What is the expected output of this code?

Question Image

Explanation

The is operator tests whether two variables refer to the same object, and these separate list literals create different list objects. The == operator compares their values, and both lists contain the same elements in the same order.

Community Discussion

No comments yet. Be the first to start the discussion!