Jason Novinger ( jnovinger@programming.dev ) M to Python@programming.dev · 2 years agoPython Performance: Why 'if not list' is 2x Faster Than Using len()blog.codingconfessions.comexternal-linkmessage-square24linkfedilinkarrow-up140
arrow-up140external-linkPython Performance: Why 'if not list' is 2x Faster Than Using len()blog.codingconfessions.comJason Novinger ( jnovinger@programming.dev ) M to Python@programming.dev · 2 years agomessage-square24linkfedilink
minus-squareMichal ( Michal@programming.dev ) linkfedilinkarrow-up4·2 years agoIt’s just how pythonic code is written. All python developers know that not and bool can indicate that variable is either empty or null. They will also use the in operator and other python specific syntax.
It’s just how pythonic code is written. All python developers know that
notandboolcan indicate that variable is either empty or null. They will also use theinoperator and other python specific syntax.