IBM Interview Question

Standard dictionary problem in Python