A standard Class C subnet with 256 addresses (254 actually available; the first is the network address and last is the broadcast address)
uses a subnet mask of 255.255.255.0. This can be expressed in binary as 11111111 11111111 11111111 00000000. If you count the ones,
there are 24 of them. A network address and a subnet mask can be written as 192.168.123.0/24, thus "/24" refers to a Class C.
A /16 has 16 bits on, 11111111 11111111 00000000 00000000 or 255.255.0.0; 172.23.0.0/16 is an example of a Class B subnet. 10.0.0.0/8 is
an example of a Class A subnet.
Now, to find out how many IP addresses are available in a subnet, and what they can be. If the subnet is a Class C or smaller
(255.255.255.anything), subtract the last number from 256 (255.255.255.0, 256-0=256, 256 possible addresses). Then subtract two (the
network and broadcast addresses), and rememer that one of your IPs has to be your router/gateway.
For 255.255.255.240 (/28), 256 - 240 = a 16-IP subnet with 14 usable IPs. For 192.168.5.128/28, the network address is (obviously)
192.168.5.128, and the broadcast address is 192.168.5.143.