so I need to loop through dictionaries of dictionaries in dictionaries. Basically I am saving information like this to a dictionary:
accounts = {}
def accountcreator():
newusername = raw_input()
newpassword = raw_input()
UUID = 0
UUID += 1
accounts[newusername] = {newpassword:UUID}
Then in another function I want to loop through all of these values, so for example this is what I have so far. This correctly loops through all of the newusernames.
def accounts():
for usernames in accounts:
#I do not know what to do from here on out
#I want it to loop through all of the newpasswords and UUID
#And the UUIDs would be saved to a new variable
Please help me, I just want a simple answer on how to loop through all of the values. Thank You!
EDIT So basically this is a example:
def accountcreator():
newusername = raw_input() #For raw input I put in cool-account-name
newpassword = raw_input() #For raw input I put in this-is-a-password
UUID = 0
UUID += 1
accounts[newusername] = {newpassword:UUID} #So basically what is being saved is accounts[cool-account-name] = {this-is-a-password:1}
So after that happens I want this to happen with the accounts function. I want it to print each separate item, so basically it would print each of the follow: username, password, and UUID. So supplied with the information above it would print Username: cool-account-name, Password: this-is-a-password, and the UUID: 1.