andioop to Programming HorrorEnglish · edit-22 years agoGod I wish there was an easier way to do thisimagemessage-square55linkfedilinkarrow-up1217arrow-down121
arrow-up1196arrow-down1imageGod I wish there was an easier way to do thisandioop to Programming HorrorEnglish · edit-22 years agomessage-square55linkfedilink
minus-squareodiumlinkfedilinkarrow-up7·2 years agoHave you tried seeing if the recursive approach runs faster?
minus-squarenoddy@beehaw.orglinkfedilinkarrow-up13·2 years agoI know an even better way. We can make it run in O(1) by using a lookup table. We only need to store 2^64 booleans in an array first.
Have you tried seeing if the recursive approach runs faster?
I know an even better way. We can make it run in O(1) by using a lookup table. We only need to store 2^64 booleans in an array first.