Mastery check
Rep 4of 8 in this section
Foundation Rep~4 min
Write: total a bill
menu is a dict mapping item names (strings) to prices (ints). order is a list of item names, possibly with repeats.
Write bill(menu, order) that returns the total price of the order. Items that are not on the menu are skipped: they add nothing.
bill({'tea': 4, 'cake': 5}, ['tea', 'pie', 'tea']) → 8
main.pylearnPython