Changed variable name dict to my_dict (avoid use reserved words).