Working with Chapter Lists and Dictionaries | Class 11 Informatics Practices Notes
By ConceptScroll Team · Published on 17 July 2026 · 3 min read
Working with Chapter Lists and Dictionaries – this guide gives you a concise, exam-ready overview of Working with Chapter Lists and Dictionaries from Class 11 Informatics Practices, written by ConceptScroll editors and reviewed against the latest NCERT textbook.
4.2 LIST OPERATIONS
Python provides several operations to manipulate lists efficiently. These include concatenation, repetition, membership testing, and slicing. Concatenation uses the '+' operator to join two or more lists, producing a new list with elements of the first list followed by the second. For example, [1,3,5] + [2,4,6] results in [1,3,5,2,4,6]. Importantly, the original lists remain unchanged unless the result is assigned to a variable. Repetition uses the '' operator to replicate the contents of a list multiple times, such as ['Hello'] 4 producing ['Hello', 'Hello', 'Hello', 'Hello']. Membership operators 'in' and 'not in' check if an element exists or does not exist in a list, returning True or False accordingly. Slicing allows extraction of a sublist from an existing list by specifying start and end indices and an optional step. For example, list1[2:6] extracts elements from index 2 to 5. Slicing supports negative indices and steps, enabling reverse traversal. These operations provide powerful tools for list manipulation and data processing.
📊 Diagram: Diagrams illustrating concatenation of two lists side by side, repetition showing multiple copies of a list, membership testing with check marks, and slicing highlighting a sublist within a larger list with start and end indices.
🧪 Activity: No specific activity in this section.
🔗 Connection: These operations are foundational for understanding list traversal and the use of list methods in the next sections.
Frequently asked questions
1. What will be the output of the following statements? a) list1 = [12,32,65,26,80,10] list1.sort() print(list1) b) list1 = [12,32,65,26,80,10] sorted(list1) print(list1) c) list1 = [1,2,3,4,5,6,7,8,9,10] list1[::-2] list1[:3] + list1[3:] d) list1 = [1,2,3,4,5] list1[len(list1)-1]
a) list1.sort() sorts the list in place. So after sorting, list1 becomes [10, 12, 26, 32, 65, 80]. The print statement outputs: [10, 12, 26, 32, 65, 80]
b) sorted(list1) returns a new sorted list but does not modify list1 itself. Since the returned sorted list is not assigned, list1 remains unchanged. So print(list1) outputs: [12, 32, 65, 26, 80, 10]
c) list1[::-2] returns a slice starting from the end towards the start, stepping by 2. So it picks elements at indices 9,7,5,3,1 (0-based): [10,8
2. Consider the following list myList. What will be the elements of myList after each of the following operations? myList = [10,20,30,40] a) myList.append([50,60]) b) myList.extend([80,90])
Initial list: myList = [10, 20, 30, 40]
a) myList.append([50,60]) adds the entire list [50,60] as a single element at the end. So myList becomes: [10, 20, 30, 40, [50, 60]]
b) myList.extend([80,90]) adds each element of the list [80,90] individually to the end of myList. So after extending, myList becomes: [10, 20, 30, 40, [50, 60], 80, 90]
3. What will be the output of the following code segment? myList = [1,2,3,4,5,6,7,8,9,10] for i in range(0,len(myList)): if i%2 == 0: print(myList[i])
The code iterates over indices 0 to 9 of myList. For each index i, if i is even (i%2 == 0), it prints myList[i]. Indices 0,2,4,6,8 are even. Corresponding elements are: 1, 3, 5, 7, 9. Hence, output will be: 1 3 5 7 9
4. What will be the output of the following code segment? a) myList = [1,2,3,4,5,6,7,8,9,10] del myList[3:] print(myList) b) myList = [1,2,3,4,5,6,7,8,9,10] del myList[:5] print(myList) c) myList = [1,2,3,4,5,6,7,8,9,10] del myList[::2] print(myList)
a) del myList[3:] deletes elements from index 3 to end. Original list: [1,2,3,4,5,6,7,8,9,10] After deletion: [1,2,3] Output: [1, 2, 3]
b) del myList[:5] deletes elements from start to index 4. Original list: [1,2,3,4,5,6,7,8,9,10] After deletion: [6,7,8,9,10] Output: [6, 7, 8, 9, 10]
c) del myList[::2] deletes elements at indices 0,2,4,6,8. Original list: [1,2,3,4,5,6,7,8,9,10] Elements at indices 0,2,4,6,8 are 1,3,5,7,9. After deletion, remaining elements are at indices 1,3,5,7,9: 2,4,6,8,10
Ready to ace this chapter?
Get the full Working with Chapter Lists and Dictionaries chapter — interactive notes, diagrams, worked solutions, polls and a free practice quiz — in the ConceptScroll app.
Study smarter with ConceptScroll
Daily NCERT-aligned reels, AI doubt solving and chapter quizzes — all free.
Start learning freeContinue reading
- Introduction to Chapter Structured Query 8 Language (SQL) | Class 11 Informatics Practices Notes
Clear NCERT-aligned notes on Introduction to Chapter Structured Query 8 Language (SQL) for Class 11 Informatics Practices.
- Introduction to Chapter Structured Query 8 Language (SQL) | Class 11 Informatics Practices Notes
Clear NCERT-aligned notes on Introduction to Chapter Structured Query 8 Language (SQL) for Class 11 Informatics Practices.
- Introduction to Chapter Structured Query 8 Language (SQL) | Class 11 Informatics Practices Notes
Clear NCERT-aligned notes on Introduction to Chapter Structured Query 8 Language (SQL) for Class 11 Informatics Practices.