I have the following dict defined
AMTVALUE1 = "string 1"
AMTVALUE2 = "string 2"
all_templates = {
"amt": AMTVALUE1,
"cmvb": AMTVALUE2,
}
when i do all_templates["amt"]
output is string 1
as expected.
I would like to know if there is a way to access the actual variable name that is being used for the key value pair? So instead of outputting string 1
, I would like to output the variable name that is used for the value.
the output would be AMTVALUE1
or AMTVALUE2