Originally Posted by
juba
I just thought of a faster way of binary calculations without doing the entire calculation.
First you would need this scheme, 128 64 32 16 8 4 2 1
Let say the number of networks is 15, immediately, I know it 4 bits
79 networks, 7 bits
63 networks, 6 bits
23 networks, 5 bits
What I am doing is taking the number of networks, 63 for example, then I look at the 128 64 32 16 8 4 2 1 scheme and determine between which two of these does the number of network falls, 63 is between 64 and 32, then I take the lower of the two, which is 32 in this case, 32 is the 5th bit in 128 64 32 16 8 4 2 1 scheme, so therefore 5 bits for 63 networks.