Why is it that I get "TypeError: can only concatenate list (not "dict") to list" when I do this:
print([1,2,3] + {-i:i*i for i in range(3)})
But this:
a = [1,2,3]
a += {-i-1:0 for i in range(3)}
print(a)
Runs as it ok and outputs this:
[1, 2, 3, -1, -2, -3]