deep_sort
deep_sort copied to clipboard
Reduce number of loops in tracker
Slightly increase spped by reducing two for loop to one
@zyc-ai a comprehension list is faster than a loop
a comprehension list is faster than a loop
It seems not in the case of Python https://stackoverflow.com/a/43677631/8791650.
a comprehension list is faster than a loop
It seems not in the case of Python https://stackoverflow.com/a/43677631/8791650.
I beg to diff, consider doing this instead
def square_sum4(numbers): return(sum([i**2 for i in numbers]))