List Manipulation Class 11 Informatics Practices Important Questions

Important Questions Class 11

Students can read the important questions given below for List Manipulation Class 11 Informatics Practices. All List Manipulation Class 11 Notes and questions with solutions have been prepared based on the latest syllabus Class 11 Notes and questions with solutions have been prepared based on the latest syllabus and examination guidelines issued by CBSE, NCERT and KVS. You should read all notes provided by us and Class 11 Informatics Practices Important Questions provided for all chapters to get better marks in examinations. Informatics Practices Question Bank Class 11 is available on our website for free download in PDF.

Important Questions of List Manipulation Class 11

Very Short answer Type Questions

Q.1 What do you understand by mutability?
Ans:
Mutable means changeable. In Python, mutable types are those whose values can be changed in place. Only three types are mutable in python – Lists, Dictionaries and Sets.

Q.2 Start with the list[8,9,10]. Do the following using list functions
(a) Set the second entry (index 1) to 17
(b) Add 4, 5 and 6 to the end of the list.
(c) Remove the first entry from the list.
(d) Sort the list.
(e) Double the list.

(f) Insert 25 at index 3
Ans:
(a) list[1]=17
(b) list.append(4)
list.append(5)
list.append(6)
(c) list.pop(0)
(d) list.sort()
(e) list=list*2
(f) list.insert(3,25)

Q.3 If a is [1, 2, 3], what is the difference (if any) between a*3 and [a, a, a]?
Ans: a*3 will produce [1,2,3,1,2,3,1,2,3], means a list of integers and [a, a, a] will produce [[1,2,3],[1,2,3],[1,2,3]], means list of lists

Q.4 If a is [1, 2, 3], is a * 3 equivalent to a + a + a?
Ans:
Yes, Both a*3 and a+a+a will produce same result.

List Manipulation Class 11 Informatics Practices Important Questions

Q.5 If a is [1, 2, 3], what is the meaning of a [1:1] = 9?
Ans:
This will generate an error “TypeError: can only assign an iterable”.

Q.6 If a is [1, 2, 3], what is the meaning of a [1:2] = 4 and a [1:1] = 4?
Ans:
These will generate an error “TypeError: can only assign an iterable”.

Q.7 What are list slices?
Ans:
List slices are the sub-part of a list extracted out. You can use indexes of the list elements to create list slices as per following format. Syntax is as follows –
Seq=ListName[start:stop]

Q.8 Does a slice operator always produce a new list?
Ans: Yes, this will create a new list.

Short Answer Type Questions

Q.1 How are lists different from strings when both are sequences?
Ans:
Lists are similar to strings in many ways like indexing, slicing, and accessing individual elements but they are different in the sense that
(i) Lists are mutable while strings are immutable.
(ii) In consecutive locations, strings store the individual characters while list stores the references of its elements.
(iii) Strings store single type of elements-all characters while lists can store elements belonging to different types.

Q.2 What are nested Lists?
Ans:
A list can have an element in it, which itself is a list. Such a list is called nested list. e.g.
L = [1,2,3,4,[5,6,7],8]

Q.3 Discuss the utility and significance of Lists.
Ans:
The list is a most versatile datatype available in Python which can be written as a list of comma-separated values (items) between square brackets. Important thing about a list is that items in a list need not be of the same type. List is majorly used with dictionaries when there is large number of data.

Q.4 What is the purpose of the del operator and pop method? Try deleting a slice.
Ans:
del operator is used to remove an individual item, or to remove all items identified by a slice. It is to be used as per syntax given below –

del List[index]
del List[start:stop]
pop method is used to remove single element, not list slices. The pop() method removes an individual item and returns it. Its syntax is –
a=List.pop() #this will remove last item and deleted item will be assigned to a.
a=List[10] # this will remove the ite at index 10 and deleted item will be assigned to a.

Q.5 What are list slices?
Ans:
List slices, like string slices are the sub part of a list extracted out. Indexes can be used to create list slices as per following format:
seq = L[start:stop]

Q.6 What do you understand by true copy of a list? How is it different from shallow copy?
Ans:
A shallow copy means constructing a new collection object and then populating it with references to the child objects found in the original. In essence, a shallow copy is only one level deep. The copying process does not recurse and therefore won‟t create copies of the child objects themselves.
True Copy means you can create a copy of a list using New_list=My_list. The assignment just copies the reference to the list, not the actual list, so both new_list and my_list refer to the same list after the assignment.

List Manipulation Class 11 Informatics Practices Important Questions

Skill Based Questions

List Manipulation Class 11 Informatics Practices Important Questions
List Manipulation Class 11 Informatics Practices Important Questions
List Manipulation Class 11 Informatics Practices Important Questions
List Manipulation Class 11 Informatics Practices Important Questions
List Manipulation Class 11 Informatics Practices Important Questions
List Manipulation Class 11 Informatics Practices Important Questions