Source: http://www.pascalp.fr/snir/res/ds/8.1.4.6%20Lab%20-%20Calculating%20IPv4%20Subnets.pdf