First page of chapter 5

This commit is contained in:
Grant Sanderson
2016-08-02 12:26:15 -07:00
parent 014b7bfdef
commit 6fe057c0f9
8 changed files with 419 additions and 20 deletions

View File

@ -122,7 +122,8 @@ def is_scene(obj):
def prompt_user_for_choice(name_to_obj):
num_to_name = {}
for count, name in zip(it.count(1), name_to_obj):
names = sorted(name_to_obj.keys())
for count, name in zip(it.count(1), names):
print "%d: %s"%(count, name)
num_to_name[count] = name
try: