In python3, (specifically 3.6 onwards) the dictionary keeps the ordering, which is great. However, I would like to initialize a dict with a kv pair 'at the end'. For example:
>>> data = {
'Z': []
# 'from': ['tos'], // adjacency list
}
>>> data['a']='b'
>>> data['b']='c'
>>> data
{'Z': [], 'a': 'b', 'b': 'c'}
Is this possible to do? What I want is as follows:
>>> data
{'a': 'b', 'b': 'c', 'Z': []} # 'Z' is the last element