abhi9u@lemmy.world to Technology@lemmy.worldEnglish · 7か月前Python Performance: Why 'if not list' is 2x Faster Than Using len()blog.codingconfessions.comexternal-linkmessage-square148linkfedilinkarrow-up1221arrow-down10cross-posted to: python@programming.dev
arrow-up1221arrow-down1external-linkPython Performance: Why 'if not list' is 2x Faster Than Using len()blog.codingconfessions.comabhi9u@lemmy.world to Technology@lemmy.worldEnglish · 7か月前message-square148linkfedilinkcross-posted to: python@programming.dev
minus-squareChaoticNeutralCzech@feddit.orglinkfedilinkEnglisharrow-up1·7か月前Yes. If it’s empty. But in cases where you need to check, it might as well not be.
Yes. If it’s empty. But in cases where you need to check, it might as well not be.