kingthrillgore@lemmy.ml to 196@lemmy.blahaj.zone · 10 months agodoes this code run rulelemmy.mlimagemessage-square44fedilinkarrow-up1293arrow-down10
arrow-up1293arrow-down1imagedoes this code run rulelemmy.mlkingthrillgore@lemmy.ml to 196@lemmy.blahaj.zone · 10 months agomessage-square44fedilink
minus-squarefrezik@midwest.sociallinkfedilinkarrow-up7·10 months agoIt jams far too much on one line. Break it up. It’s a mistake I see a lot on Python.
minus-squarestebo02@sopuli.xyzlinkfedilinkarrow-up4·10 months agobut if you do it as a for loop it would be slower
minus-squarefrezik@midwest.sociallinkfedilinkarrow-up3·10 months agoUnless you’re looping over more than a million elements, that’s a poor excuse.
minus-squarestebo02@sopuli.xyzlinkfedilinkarrow-up4·10 months agoor you’re doing this a million times
I’d say this is pretty readable
It jams far too much on one line. Break it up. It’s a mistake I see a lot on Python.
but if you do it as a for loop it would be slower
Unless you’re looping over more than a million elements, that’s a poor excuse.
or you’re doing this a million times