Persona3Reload@lemmy.blahaj.zone to 196@lemmy.blahaj.zoneEnglish · 1 day agoRulelemmy.blahaj.zoneimagemessage-square53fedilinkarrow-up1364arrow-down16
arrow-up1358arrow-down1imageRulelemmy.blahaj.zonePersona3Reload@lemmy.blahaj.zone to 196@lemmy.blahaj.zoneEnglish · 1 day agomessage-square53fedilink
minus-squaredadarobot@lemmy.sdf.orglinkfedilinkarrow-up18arrow-down3·1 day agoIf number%2 == 0: return("Even") Else: return("odd")
minus-squareistdaslol@feddit.orglinkfedilinkarrow-up4·23 hours agoNot all ARM CPUs support mod operations. It’s better to use bit operations. Check if the last bit is set. If set it’s odd else it’s even.
If number%2 == 0: return("Even") Else: return("odd")
Not all ARM CPUs support mod operations. It’s better to use bit operations. Check if the last bit is set. If set it’s odd else it’s even.
I came here to post this