3 ms·
I was actually not describing adding elements to a container, but adding up values.
by einpoklum 6y ago
I was actually not describing adding elements to a container, but adding up values.
- owl57 6y agoSee? That's the problem with arithmetic on containers. Python has that already: v += 4, 5, 6 Comma doesn't do weird shit: that's just a tuple of numbers. But "+=" then does weird shit: it means concatenation when v is a standard library list, and element-wise addition when v is a numpy vector.