Python Lists
Lists are Python’s most Flexible Ordered Collection of Object Types.
A List is Created by placing Values inside of Square Brackets, Separated by Commas.
Lists are Typically Assigned a Variable Name.
Do Not begin Variable Names with a Number... Guaranteed Error!
Example:
Unlike other Programming Languages...
Python Lists can Contain any type of Object:
Numbers
Strings
Even other Lists
Wow... Gotta Love Python.
Accessing Lists
The List Items are Stored and Accessed based on Index... Starting with Index 0.
Here are Some Examples of Accessing List Items:
Manipulating Lists
Lists are Really Simple to Manipulate.
Here are Some Examples of Changing and Sorting Lists:
Combining Lists
Merging or Combining Lists Together can be Tricky.
Here are Some Examples of Combining Lists: