Is not both are right?
def report():
"""It prints the value of each resource"""
print(f"resources['water']: {resources['water']}")
print(f"resources['milk']: {resources['milk']}")
print(f"resources['coffee']: {resources['coffee']}")
print(f"resources['money']: {resources['money']}")
vs
print(f"resources{['water']}")
print(f"resources{['milk']}")
print(f"resources{['coffee']}")
print(f"resources{['money']}")
hi i tried to acess the dictionary values within the function but it isnot working.I questioned GPT & it spit out the first version which miraculously worked but i couldnot figure out why my version didnot work.