x = "/a"l = x.split("/")d = {}for v in l: d[v] = 10 print(d)
Standard input is empty
{'': 10, 'a': 10}
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!