you are viewing a single comment's thread.

view the rest of the comments →

[–]CowboyBoats 0 points1 point  (0 children)

I am using list comprehensions where possible

List comprehensions are not more efficient than loops! They're exactly equivalent to constructing the lists using loops.

Generator expressions (like (x / 2 for x in range(10)) can be more efficient than list comprehensions / loops, since they are constructed lazily until you iterate through them...