# [ ] review and run example
# the list before append
sample_list = [1, 1, 2]
print("sample_list before: ", sample_list)
sample_list.append(3)
# the list after append
print("sample_list after: ", sample_list)
# [ ] review and run example
# append number to sample_list
print("sample_list start: ", sample_list)
sample_list.append(3)
print("sample_list added: ", sample_list)
# append again
sample_list.append(8)
print("sample_list added: ", sample_list)
# append again
sample_list.append(5)
print("sample_list added: ", sample_list)
# [ ] run this cell several times in a row
# [ ] run cell above, then run this cell again
# [ ] review and run example
mixed_types = [1, "cat"]
# append number
mixed_types.append(3)
print("mixed_types list: ", mixed_types)
# append string
mixed_types.append("turtle")
print("mixed_types list: ", mixed_types)
# Currency Values
# [ ] create a list of 3 or more currency denomination values, cur_values
# cur_values, contains values of coins and paper bills (.01, .05, etc.)
# [ ] print the list
cur_values = [1, 5, 10, 20, 50]
# [ ] append an item to the list and print the list
print(cur_values)
cur_values.append(100)
print(cur_values)
# Currency Names
# [ ] create a list of 3 or more currency denomination NAMES, cur_names
# cur_names contains the NAMES of coins and paper bills (penny, etc.)
# [ ] print the list
cur_names = ['dollar', 'five dollars', '10 dollars', 'twenty dollars', ]
# [ ] append an item to the list and print the list
print(cur_names)
cur_names.append("fifty dollars")
print(cur_names)
# [ ] append additional values to the Currency Names list using input()
# [ ] print the appended list
add_cur_name = input("Enter a US dollar").lower()
cur_names.append(add_cur_name)
print(cur_names)
# [ ] complete the Birthday Survey task above
bday_survey = []
while True:
bday = input("Please enter the day you were born without the month or year and type exit when finished" ).lower()
if bday != "exit":
bday_survey.append(bday)
else:
print("List ended")
break
print("Your Birthday:", bday_survey)
# [ ] Fix the Error
three_numbers = [1, 1, 2]
print("an item in the list is: ", three_numbers[2])