Comment on Is the bitwise AND of subnet masks and IP addresses redundant?

DmMacniel@feddit.org ⁨2⁩ ⁨months⁩ ago

But why do we need the bitwise AND for that, specifically? I understand the idea, but would it not be easier to only parse the IP address string of bits only for the first n bits and then disregard the remainder (the host identifier)?

Essentially it boils down to:

bit operations are stupid fast, String operations are super slow.

source
Sort:hotnewtop