A school lab needs a new IPv4 subnet with at least 50 usable hosts and with as little wasted address space as possible. Which prefix should the lab choose?
Select an answer to reveal the explanation.
Short Explanation
You want the smallest room that still seats the class, not the auditorium and not a closet. A /26 gives you 62 usable hosts, which covers 50, and it wastes less space than a /25 or a /24. A /27 stops at 30 usable hosts, so it looks thrifty and still leaves the lab short.
Full Explanation
Usable IPv4 hosts in a prefix are 2^(32-prefix)-2, subtracting the network address and the broadcast address. A /26 is 2^(32-26)-2 = 2^6-2 = 64-2 = 62 usable hosts. That meets 50 and is the smallest prefix in this set that does. A /27 is 2^(32-27)-2 = 2^5-2 = 32-2 = 30 usable hosts. Thirty is below 50, so the lab would not have enough addresses no matter how little space the prefix wastes. A /25 is 2^(32-25)-2 = 2^7-2 = 128-2 = 126 usable hosts. It covers 50 and leaves far more unused addresses than the 62-host /26, so it fails the least-waste requirement. A /24 is 2^(32-24)-2 = 2^8-2 = 256-2 = 254 usable hosts. It also covers 50 and wastes still more of the address plan than either the /25 or the /26. The prefix that satisfies both conditions is the /26. Exam caveat: the minus two applies to a normal subnet that reserves a network address and a broadcast address. Do not count 64, 32, 128, or 256 as the usable total when the question asks for hosts. Operational check: write the lab requirement as 50 usable, compute 2^(32-prefix)-2 for the candidate prefixes, reject anything under 50, and pick the longest prefix that remains.