Jason Novinger@programming.devM to Python@programming.dev · 1 day agoPython Performance: Why 'if not list' is 2x Faster Than Using len()blog.codingconfessions.comexternal-linkmessage-square36linkfedilinkarrow-up149arrow-down14cross-posted to: technology@lemmy.world
arrow-up145arrow-down1external-linkPython Performance: Why 'if not list' is 2x Faster Than Using len()blog.codingconfessions.comJason Novinger@programming.devM to Python@programming.dev · 1 day agomessage-square36linkfedilinkcross-posted to: technology@lemmy.world
minus-squareflatbield@beehaw.orglinkfedilinkEnglisharrow-up3·edit-215 hours agoCompact does not mean easier to understand. They are different tests. The point is, do not make code less readable for speed unless speed matters. I am not going to argue which is more readable in any specific case. That is up to the developer.
Compact does not mean easier to understand. They are different tests. The point is, do not make code less readable for speed unless speed matters. I am not going to argue which is more readable in any specific case. That is up to the developer.