Calculate how many subnets can be created from a network with a given prefix length.
Subnetting works by borrowing bits from the host portion of an address and reassigning them to the network portion. Borrowing n bits multiplies the number of subnets by 2^n while dividing the hosts available per subnet accordingly. The new prefix length is simply the original prefix plus the number of borrowed bits.
Subnets from borrowed bits
subnets = 2^borrowed_bits
It means taking bits that were previously part of the host identifier and using them instead to identify individual subnets, which increases the prefix length by that many bits.
2^3 = 8 subnets. Each additional borrowed bit doubles the subnet count while halving the hosts available in each subnet.
Yes — every bit borrowed for subnets is a bit no longer available for hosts, so you gain more, smaller subnets at the cost of fewer usable addresses per subnet.