4 ms·
You mean concatenating the lists or pairwise addition? I don't expect the former to be slow in python as it would be a primitive implemented in C (although eve
by gpderetta 4y ago
You mean concatenating the lists or pairwise addition?
I don't expect the former to be slow in python as it would be a primitive implemented in C (although even a simple lisp interpreter can have an advantage here by just concatenating the conses).
For the latter, any language runtime capable of inference should be able to optimize it.