list1
|
---|
The entire list | [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
|
---|
The length of the list | 10
|
Element 0 and element 1 | 0 and 1
|
Elements 1 through 5 only | [1, 2, 3, 4, 5]
|
list1 after change, insert & append | ['zero', 1, 2, 3, 3.01, 4, 5, 6, 7, 8, 9, 10]
|
list1 after delete 4th element | ['zero', 1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
|
list1 after delete element 10 | ['zero', 1, 2, 3, 4, 5, 6, 7, 8, 9]
|
list2
|
---|
The entire list | ['dog', 'cat', 'pig', 'cow', 'duck', 'bird']
|
---|
Does element value='cat' exist? | True , in position: 1
|
Converting the list to a string | dog_cat_pig_cow_duck_bird
|
Converting the string back to a list | ['dog', 'cat', 'pig', 'cow', 'duck', 'bird']
|
Sorting list2 list ascending | ['bird', 'cat', 'cow', 'dog', 'duck', 'pig']
|
Sorting list2 list descending | ['pig', 'duck', 'dog', 'cow', 'cat', 'bird']
|
list3 (2 Dimensional)
|
---|
The entire 2 dimensional list | [[1, 'Barbara', 'Burns', '000-01-0001', 'F'], [2, 'Vincent', 'Cambria', '000-01-0002', 'M'], [3, 'Duncan', 'Davidson', '000-01-0003', 'M']]
|
---|
Row 1 only | [1, 'Barbara', 'Burns', '000-01-0001', 'F']
|
Row 2, column 5 | M
|
The length of list3 list | 3
|
The length of list3 row 1 | 5
|
Adding a new inner list to list3 | [4, 'Sam', 'Sultan', '000-01-0004', 'M']
|
Sorting list3 on column 2 ascending | [[1, 'Barbara', 'Burns', '000-01-0001', 'F'], [3, 'Duncan', 'Davidson', '000-01-0003', 'M'], [4, 'Sam', 'Sultan', '000-01-0004', 'M'], [2, 'Vincent', 'Cambria', '000-01-0002', 'M']]
|
Sorting list3 on column 2 descending | [[2, 'Vincent', 'Cambria', '000-01-0002', 'M'], [4, 'Sam', 'Sultan', '000-01-0004', 'M'], [3, 'Duncan', 'Davidson', '000-01-0003', 'M'], [1, 'Barbara', 'Burns', '000-01-0001', 'F']]
|