मराठी

Consider the following list myList. What will be the elements of myList after the following operation: myList = [10,20,30,40] myList.append([50,60]) - Computer Science (Python)

Advertisements
Advertisements

प्रश्न

Consider the following list myList. What will be the elements of myList after the following operation:

myList = [10,20,30,40]

myList.append([50,60])
टीपा लिहा

उत्तर

append() function takes only one argument and inserts the element to the end of the list. Here, the argument is a list containing the elements 50, and 60. Therefore, the output will be: [10, 20, 30, 40, [50, 60]].

shaalaa.com
List Methods and Built-in Functions
  या प्रश्नात किंवा उत्तरात काही त्रुटी आहे का?
पाठ 9: Lists - Exercise [पृष्ठ २०४]

APPEARS IN

एनसीईआरटी Computer Science [English] Class 11
पाठ 9 Lists
Exercise | Q 2. i. | पृष्ठ २०४
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×