Destide@feddit.uk to Programmer Humor@lemmy.mlEnglish · 2 months agoInfallible Codelemmy.mlimagemessage-square92fedilinkarrow-up1341arrow-down116
arrow-up1325arrow-down1imageInfallible Codelemmy.mlDestide@feddit.uk to Programmer Humor@lemmy.mlEnglish · 2 months agomessage-square92fedilink
minus-squaresik0fewl@lemmy.calinkfedilinkarrow-up11·2 months agoThis code would run a lot faster as a hash table look up.
minus-squarePieMePlenty@lemmy.worldlinkfedilinkarrow-up5·2 months agoI agree. Just need a table of even numbers. Oh and a table of odd numbers, of course, else you cant return the false… duh.
minus-squareValmond@lemmy.worldlinkfedilinkarrow-up4·2 months agoIn a Juliana tree, or a dictionary tree if you want. For speed.
This code would run a lot faster as a hash table look up.
I agree. Just need a table of even numbers. Oh and a table of odd numbers, of course, else you cant return the false… duh.
In a Juliana tree, or a dictionary tree if you want. For speed.