List
Python Lists
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. The important thing about a list is that items in a list need not be of the same type.
Creating a list is as simple as putting different comma-separated values between square brackets.
For example:
list1 = ['math', 'history', 2005, 2019]; list2 = [1, 2, 3, 4, 5 ]; list3 = ["a", "b", "c", "d"]
List
Reviewed by ohhhvictor
on
May 06, 2019
Rating:
![List](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg0Bzyii0L3E0e5Dekw_kQ_1cI-88gkYHNQ-6OpnGTTcXyRrBkkztJI4ji8CVdAtTOQQAOLH8BpVDMgwu2E76NLHWsll_sk-zheTlNB4FujntTCTYrUAGGmGzBVTko_aETZK7DeznRb8sM/s72-c/list303.png)
No comments: