In this article we will talk about important QnA List methods class 11. As usual we will see objective type questions and then subjective type questions. Here we go!

Objective type Questions – QnA List methods class 11

In the objective type questions – QnA List methods class 11, you will get fill in the blanks, MCQs and True false that is 1 mark.

  1. A __________ is a standard library that returns the total number of elements of the list.
  2. What will be the output of: l = [[1,2,3],[4,5,6],7]; print(len(l))?
    1. 3
    2. 7
    3. 2
    4. None of these
  3. Which of the following function is used to convert any sequence/object into a list object?
    1. l[]
    2. list()
    3. convert_list()
    4. l.list()
  4. You cannot convert any tuple, dictionary object into the list. (True/False)
  5. What will the output of l=[22,33,45,67,89]; print(l.index(67))?
    1. 4
    2. 3
    3. 67
    4. -2
  6. When the element is not present in the list and user try to find out the index of a given element, it returns:
    1. index not found
    2. Error – Element is not in list
    3. 0
    4. None
  7. Which of the following method is used to add a single element to the existing list?
    1. add()
    2. extend()
    3. addelement()
    4. append()
  8. Which of the following method is used to insert multiple elements into the list?
    1. add()
    2. append()
    3. extend()
    4. insert()
  9. The append() and extend() method add an element to the end of the list. (True/False)
  10. The _____________ method add an element at specified index or position.
  11. The ___________ method removes the last element from the list.
  12. The ___________ list method removes the specified element.
  13. The ________________ list method removes all the elements from the list.
  14. Which of the following method will count the frequency of the list elements?
    1. count()
    2. list_count()
    3. countElement()
    4. countFrequency()
  15. The reverse method returns the list in reverse order of the elements in place. (True/False)
  16. Which of the following parameter is required to return the list in descending order with sort method?
    1. order=descending
    2. sort!=ascending
    3. reverse=True
    4. orderby=descending
  17. Which of the following method returns a new list after rearranging the list elements?
    1. sort()
    2. sorted()
    3. list_sort()
    4. sort()=new list()
  18. You can print the maximum and minimum values from the list using max() and min() methods.
  19. Which of the following list method is used to return the addition of all list elements?
    1. add()
    2. sum()
    3. autosum()
    4. listSum()
  20. You can remove an element by specifying its index using the pop method. (True/False)

Let’s have a look at answers for objective type questions QnA List methods class 11.

 

  1. len()
  2.  3
  3. list()
  4. False
  5. 3
  6. Error – is not in list
  7. append()
  8. extend()
  9. True
  10. insert()
  1. pop()
  2. remove()
  3. clear()
  4. count()
  5. True
  6. reverse=True
  7. sorted()
  8. True
  9. sum()
  10. True

Subjective Type questions

  1.  Write the significance use of following standard methods.
    1. len
    2. list
  2. Find the output:
    1. l=list(‘ListMethods’);print(l)
    2. l=((78,90,12,34));print(l)
    3. l=list({‘Karthik’:90,’Manoj’:85})
  3. What is the use of index() method? Explain with example.
  4.  Explain the ValueError exception with example.
  5. Differentiate between append(),extend() and insert() methods.
  6. Differentiate between pop(), remove() and clear() methods.
  7. What is the use of count() method? Explain with example.
  8. Justify the statement: “reverse() does not return anything.”
  9. Differentiate between sort() and sorted() methods.
  10. What do you mean two-dimensional lists?
  11. How to create and traverse 2D lists?

Output Questions:

[1] 
l1 = [78,89,67,45,69,42,89,] n = l1.index(89) + l1.index(42) print(l1.count(89)) l1.append(l1.count(100)+34) print(l1.len())
 [2]
l1=[56,45,23,12,'ABC']
l1.extend([85,63])
l1.insert(3,99)
l1.pop()
print(l1)
l1.insert(0,101)
l1.insert(2,111)
l1.pop(2)
l1.remove('ABC')
print(l1)
[3]
l = [9,5,3,6,7,8]
l.sort()
l.reverse()
print(l)
n=sum(l)+max(l)+min(l)
print(n)

Now let’s see some error questions for QnA List methods Class 11:

Error Based Questions

[1]

l = (9,5,3,6,7,8)
print(l.len())

[2]

rno=int(input("Enter the rollno:"))
stu_name=input("Enter the name:")
fees=int(input("Enter the Fees:"))
stu_rec=list(rno,stu_name,fees)
print(stu_rec)
l.index(fees)
l.append('Manali')
l.insert(56)

[3]

l=['Jan','Feb','Mar','Apr']
l.index(2)
l.remove('Jun')
print(sort(l))
n = l.max()

So I hope you will learn something from this article.

Like and share the article with your friends and in social media groups.

Thank you for visiting the blog.

You can ask your doubts and queries through comments.

Recommended – List Methods in Python

Computer Science Class 11

Leave a Reply