Question 3 of 14beginner💡 UnderstandShort Answer2 marks

"Lists and Tuples are ordered". Explain.

Correct Answer

Lists and Tuples are called ordered sequences because each element in them has a fixed position. This means that the elements are stored in a specific sequence, and their order remains constant.

Since elements have a fixed position, they can be accessed using indexing. The index values start from 0 for the first element. Two-way indexing holds in both lists and tuples, which means we can use positive indexing (from left) and negative indexing (from right) to access elements. Additionally, slicing can be used to access a range of elements from these sequences, just like in strings.

Exercise: EXERCISE | Q: 3 | (Page 18)
For More Understanding

Explanation

The textbook explicitly states that 'Tuples are ordered sequences as each element has a fixed position.' It also mentions that 'Like list and string, elements of a tuple can be accessed using index values, starting from 0' and that 'Elements of a tuple can be accessed in the same way as a list or string using indexing and slicing.' The concept of 'two way indexing' is also mentioned in the context. This question tests the student's understanding of the fundamental property of ordered sequences in Python.