Page 127 - Plus V4 with Adobe class 8
P. 127

Let us write a Python program to print the different types of lists.












            On running the above program, you will get the following output:













            Nested List

            A list that contains another list is called a nested list. The example of the nested list is given as follows:

            To create nested list: L1 = [’Orange’, 2.0, 5, [10,20]]

            Let us write a Python program to print the nested list.











            On running the above program, you will get the following output:



















                     Double Tap                                                 Century   #Information Literacy
                                                                                   21 st
                                                                                  Skills
                   1.  Write the syntax to create a list.



                   2.  Write an example of nested list.





                                                                                                #List in Python 125
   122   123   124   125   126   127   128   129   130   131   132