<｜begin▁of▁sentence｜>### Instruction:
As a community health worker, you are tasked with managing health education resources for various community members. In order to accomplish this, you may want to store multiple resources under the same topic or category, such as "nutrition" or "exercise." How would you use a MultiDict to store these resources and then retrieve the list of all resources associated with a particular topic?
### Response:
from multidict import MultiDict

# Create a MultiDict object
d = MultiDict()

# Add a key-value pair to the MultiDict
d.add('spam', 'ham')
# Retrieve the value for 'spam'
print(d['spam'])

# Add another value to the same key
d.add('spam', 'eggs')
# Retrieve all values associated with 'spam'
print(d.getlist('spam'))
<|EOT|>
