In python, I understand it's possible to convert many types of data to a string using str(). Is there any way to reverse this? Let me show you what I mean.
exampleDictionary = {'thing on ground': 'backpack'}
backpack = {'tea': 'Earl Grey'}
def openBackpack():
#code to grab backpack from exampleDictionary
#code to convert 'backpack' to backpack
#code to access backpack and look at the tea
This is oversimplified of my code in progress, but it should be easy to see basically where I'm stuck at. If it's not clear I'm happy to clarify further.