In Python, a list is an ordered sequence of heterogeneous elements. In other words, a list can hold elements with different data types. For example,

list = ['a', 'apple', 23, 3.14] 

Initializing a list #

Level up your interview prep. Join Educative to access 70+ hands-on prep courses.