Changes

Jump to: navigation, search

OPS435 Python Lab 4

12 bytes removed, 17:25, 15 June 2017
PART 3 - Dictionaries
list_of_keys = list(dict_york.keys())
list_of_keys[0]
</source>::#In addition, lists can be changed into sets if we would like to perform comparisons with another set<br><br>::#. To demonstrate, issue the following:<source>
set_of_keys = set(dict_york.keys())
set_of_values = set(dict_york.values())
set_of_keys | set_of_values
</source>::#Lists can be used with '''for loops'''. To Demonstrate, issue the following for loops.:<source>
list_of_keys = list(dict_york.keys())
for key in list_of_keys:
13,420
edits

Navigation menu