pastebin

Paste Search Dynamic
Recent pastes
d result
  1. d = {"result" : [{"159" : [{"name" : "a", "age" : "10"}, {"name" : "b", "age" : "11"}]}, {"160" : [{"name" : "c", "age" : "12"}, {"name" : "d", "age" : "13"}]}]}
  2. print(d)
  3. print()
  4. print(d["result"])
  5. print()
  6.  
  7. result = {}
  8. temp = d["result"]
  9.  
  10. for i in temp:
  11.         for key, value in i.items():
  12.                 result[key] = value
  13.  
  14. d["result"] = result
  15. print(d)
Parsed in 0.005 seconds