Class 11 List Manipulation MCQ Quiz Preview Created by Lucky Class 11 List Manipulation Quiz 1 / 46 What is the output of the following?names= ['Hasan' ,'Balwant', 'Sean','Dia']print(names[-1][-1]) Hasan a h Dia n 2 / 46 Given a list l=[10,20,30 40,50,60]What would L[2 : -2] return? [20,30,40] [30,40] [20,30] [10,20,30,40] 3 / 46 Which of he following can't delete an element from a list if the index of the element is given ? remove( ) del pop ( ) 4 / 46 The insert () can add an element in the middle of a list. True False 5 / 46 lists are ____ data types and thus their values can be changed. Mutability mutable immutability 6 / 46 The ____ operator replicates a list * - + 7 / 46 If LI =[1,3,5]and L2=[2,4,6] then L1+L2 will yield [1,3,5, [2,4,6]] [3,7,11] [ 1,2,3,4,5,6] [1,3,5,2,4,6] 8 / 46 The ___ function can append a list of elements to a list. extend insert pop 9 / 46 The ___ operator adds one list to the end of another list. * & + 10 / 46 A ___ list contains another list as its member . if-else if nested 11 / 46 What is correct syntax to copy one list into another ? listA=listB[:] listA=listB[]() listA=list(listB) listA=listB[ ] 12 / 46 The POP( ) and remove( ) are similar functions. True False 13 / 46 Which of the following can add only one value to a list? add( ) append( ) extend( ) none of these 14 / 46 To sort a list, sort() and sorted (), both can be used. True False 15 / 46 The append() can add an element in the middle of a list. False True 16 / 46 Consider the list alist =["PTK", [1,5.5,8] ]. What would the following code print ?print(alist[0][1], alist[1] [1] ) T,5 T,5.5 T,1 T,8 17 / 46 To check if an element is not in list, _____ operator is used . in,not in in not in 18 / 46 To delete a list slice from a list , ____ is used . delimiter del statement extend( ) 19 / 46 Given a list L=[10,20,30,40,50,60,70]What would L[-3 : 99]return ? [40,50,60] [20,30,40] [50,60,70] [30,40,50] 20 / 46 Given a list L=[10,20,30,40,50,60,70 ] What would l[1 :4] return ? [20,30,40,50] [10,20,30,40] [ 30,40,50] [20,30,40] 21 / 46 Which of the following commands will create a list ? all of these list1=list( ) list1=[ ] list1=list([1,2,3]) 22 / 46 What is the output when we execute list("hello") ? ['h','e','l','l','o']. ['llo']. ['hello']. ['olleh']. 23 / 46 List can contains values of these types : Lists tuples Integers All of these floats 24 / 46 Which of the following can't add a list of elements to a list ? extend( ) append( ) 25 / 46 The ___ function sorts a list and returns another list . sorted list open 26 / 46 Which of the following will create an empty list ? L=[ ] L= list( ) L=list(empty) L= list (0) 27 / 46 If L=[1,2] then L*2 will yield [1,1,2,2] [1,2,1,2] [1,2] * 2 [ 1,2,2] 28 / 46 The ___ function is used to insert an element at a designated position in a list nested list insert 29 / 46 The ____ function is used to delete an element from a designated index in a list . append( ) extend( ) pop ( ) 30 / 46 Lists once created cannot be changed . False True 31 / 46 Which of the following will always returns a list ? sort( ) min( ) max( ) sorted( ) 32 / 46 The extend () adds a single element to a list . True False 33 / 46 Which of the following can copy a list to another list ? new( ) copy( ) list( ) = operater 34 / 46 The del statement can only delete list slices and not single elements from a list . False True 35 / 46 What is printed by the Python code ?print (list (range(3))) [1,2,3] [0,1,2,3] 0,1,2 [0,1,2] 36 / 46 The ___ function sorts a list and makes changes in the list . append sorted sort 37 / 46 Which of the following can delete an element from a list if the index of the element is given ? all of these remove( ) pop ( ) del 38 / 46 Which of the following will return the last element of a list L with 5 elements ? L[4] l [-1] L[5] L[6] 39 / 46 What is the output of the following L=[None]* 10print(len(L)) 0 None 10 Syntax Error 40 / 46 Which of the following searches for an element in a list and returns its index ? find( ) Isearch( ) search( ) index( ) 41 / 46 To find the last element of list namely Smiles in Python,___ will be used. smiles[:-1] smiles[lpos] smiles[-1] smiles[0] 42 / 46 The del statement can work similar to the pop() function.will give output True False 43 / 46 To create a empty list, function __ can be used. list( ) append( ) new( ) 44 / 46 A = [] and A = list () will produce the same result . True False 45 / 46 Which of the following is a standard Python library function and not an exclusively list function ? append( ) remove( ) len( ) 46 / 46 The list() and copy() are the similar functions . False True Your score is Facebook Twitter VKontakte 0% Restart quiz Exit Lesson tags: python quiz for class 12 Python Quiz-V | Python Quiz on Data Handling Class 11 Tuples MCQ Quiz Back to: CBSE class 11 Computer Science Notes