FIX: Subnet mask calculation based on number of hosts
Subnet mask depends on number of hosts in the block. It can be calculated by subtracting Log2 of the number of hosts from the 32 bit lenght of the mask.
Example: 256 hosts, 8 bits used for the hosts portion (Log2(256)), 24 bits on the mask (32-8). 1024 hosts, 10 bits used for the hosts portion (Log2(1024)), 22 bits subnet mask (32-10).
Fixed SUBNET calculation.