employee = {'name': 'John', 'age': 31, 'city': 'New York'} print(employee)
{'name': 'John', 'age': 31, 'city': 'New York'}
employee = {'name': 'John', 'age': 31, 'city': 'New York'} employee['salary'] = 5000 print(employee)
{'name': 'John', 'age': 31, 'city': 'New York', 'salary': 5000}
employee = {'name': 'John', 'age': 31, 'city': 'New York'} del employee['city'] print(employee)
{'name': 'John', 'age': 31}
employee = {'name': 'John', 'age': 31, 'city': 'New York'} print(employee['name'])
John
标签: css