Persona3Reload@lemmy.blahaj.zone to 196@lemmy.blahaj.zoneEnglish · 14 days agoRulelemmy.blahaj.zoneexternal-linkmessage-square57fedilinkarrow-up1387arrow-down14
arrow-up1383arrow-down1external-linkRulelemmy.blahaj.zonePersona3Reload@lemmy.blahaj.zone to 196@lemmy.blahaj.zoneEnglish · 14 days agomessage-square57fedilink
minus-squaredadarobot@lemmy.sdf.orglinkfedilinkarrow-up18arrow-down3·14 days agoIf number%2 == 0: return("Even") Else: return("odd")
minus-squareistdaslol@feddit.orglinkfedilinkarrow-up4·14 days 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.
Deleted