hentet fra
http://en.wikipedia.org/wiki/Classless_Inter-Domain_RoutingCIDR notation
The standard notation for a CIDR address range begins with the network address (padded on the right with the appropriate number of zero-valued bits - up to 4 octets for IPv4, and up to 8 16-bit hexadecimal fields for IPv6). This is followed by a "/" character and a prefix length, in bits, specifying the number of 1's in the subnet mask, which determines the size of the network part of an IP address.
For example (a more complete IPv4 subnetting reference table is available):
* 192.168.0.0/24 represents the 256 IPv4 addresses 192.168.0.0 through 192.168.0.255 inclusive, with 192.168.0.255 being the broadcast address for the network.
* 192.168.0.0/22 represents the 1024 IPv4 addresses 192.168.0.0 through 192.168.3.255 inclusive, with 192.168.3.255 being the broadcast address for the network.
* 2002:C0A8::/48 represents the IPv6 addresses 2002:C0A8:0:0:0:0:0:0 through 2002:C0A8:0:FFFF:FFFF:FFFF:FFFF:FFFF, inclusive.
For IPv4, an alternative representation uses the network address followed by the network's subnet mask, written in dotted decimal form:
* 192.168.0.0/24 could be written 192.168.0.0 255.255.255.0
* 192.168.0.0/22 could be written 192.168.0.0 255.255.252.0
CIDR CIDR Class Hosts Mask
/32 1/256 C 1 255.255.255.255
/31 1/128 C 2 255.255.255.254
/30 1/64 C 4 255.255.255.252
/29 1/32 C 8 255.255.255.248
/28 1/16 C 16 255.255.255.240
/27 1/8 C 32 255.255.255.224
/26 1/4 C 64 255.255.255.192
/25 1/2 C 128 255.255.255.128
/24 1 C 256 255.255.255.000
/23 2 C 512 255.255.254.000
/22 4 C 1024 255.255.252.000
/21 8 C 2048 255.255.248.000
/20 16 C 4096 255.255.240.000
/19 32 C 8192 255.255.224.000
/18 64 C 16384 255.255.192.000
/17 128 C 32768 255.255.128.000
/16 256 C, 1 B 65536 255.255.000.000
/15 512 C, 2 B 131072 255.254.000.000
/14 1024 C, 4 B 262144 255.252.000.000
/13 2048 C, 8 B 524288 255.248.000.000
/12 4096 C, 16 B 1048576 255.240.000.000
/11 8192 C, 32 B ? 255.224.000.000
/10 16384 C, 64 B ? 255.192.000.000
/9 32768 C, 128B ? 255.128.000.000
/8 65536 C, 256B ? 255.000.000.000
/7 131072 C, 512B ? 254.000.000.000
/6 262144 C, ? 252.000.000.000
/5 524288 C, ? 248.000.000.000
/4 1048576 C, ? 240.000.000.000
/3 ? ? 224.000.000.000
/2 ? ? 192.000.000.000
/1 ? ? 128.000.000.000
/0 ? ? 000.000.000.000