I'm using Python 2.7 and I want to use something as Javascript spread operator.
I have followin code:
def some_function():
return {
'a': "test",
'b': 1,
'c': 2
}
mapper = some_function()
test = mapper.update({'a': "Updated"})
print(test)
The result that I want is:
{
'a': "Updated",
'b': 1,
'c': 2
}
But I get None
instead.
Any idea?