3 ms·
That syntax doesn't make sense. The {**d1, **d2} idiom is just a clever mashup of Python's dictionary construction literal {}, and * * unpacking. That's w
by mturmon 8y ago
That syntax doesn't make sense. The
{**d1, **d2}
idiom is just a clever mashup of Python's dictionary construction literal {}, and * * unpacking. That's why it only works with string-valued keys (which is a major limitation).
Adding a third item to the dictionary literal would require special-casing the {} dictionary construction literal.