Q:

Adding items to dictionary from a dictionary

I want to copy an item from one list to another. For example:
chest = {}

chest["sword":1,3]
chest["gold":5]

inventory = {}

inventory.add(chest["sword"])    #example pseudo code

How would I add 1 item from "chest" to "inventory", keeping the key name, and values?
Thanks for any help!
EDIT TO AVOID CONFUSION:
I want to be able to add a SINGLE item from, say "chest" to "inventory". so:
inventory = {}
chest = {"sword":1, "gold":5, "other item":"other data"}

I want to take 1 item from "chest" (depending on user input) and add it to "inventory":
inventory.add( chest [ item_from_chest ] ) #exampe pseudo code

after this inventory world look like this:
>>>{"sword":1}

Sorry for any confusion, hope this edit helps!

A:

You can use dictionary update():

Update the dictionary with the key/value pairs from other, overwriting
  existing keys.

>>> chest = {}
>>> chest = {"sword": 1, "gold": 5}
>>> inventory = {}
>>> inventory.update(chest)
>>> inventory
{'sword': 1, 'gold': 5}

Or, if you need just one sword item, simply:
>>> inventory['sword'] = chest['sword']
>>> inventory
{'sword': 1}

Or, if there are several keys you need to copy (but not all of them):
>>> keys_to_copy = ['sword']
>>> inventory.update(((key, chest[key]) for key in keys_to_copy))
>>> inventory
{'sword': 1}

