Difficulty: Medium
Correct Answer: 2,046
Explanation:
Introduction / Context:
Knowing how to compute hosts per subnet is essential for IP addressing plans. This problem focuses on a Class B network using a subnet mask with 248 in the third octet, a common way to describe 255.255.248.0. You must convert the mask to prefix length and then compute usable hosts.
Given Data / Assumptions:
Concept / Approach:
Compute prefix length by counting mask bits. Then use the formula hosts per subnet = 2^(host_bits) - 2. Here, 248 corresponds to 11111000 in binary, providing 5 bits of subnetting in the third octet and leaving 3 bits in the third plus 8 bits in the fourth for hosts? Instead, treat it uniformly: a /21 mask leaves 11 host bits across the last two octets.
Step-by-Step Solution:
Verification / Alternative check:
Use a subnet calculator or quick table: /24 → 254 hosts; adding three more host bits (/21) multiplies by 2^3 = 8, giving 254 * 8 + small rounding to the precise 2046. Both methods agree.
Why Other Options Are Wrong:
a: 16,382 corresponds to /18 (14 host bits) not /21.
b: 8,190 aligns with /19 (13 host bits) not this mask.
c: 4,094 is /20 (12 host bits) not /21.
e: 1,022 is /22 (10 host bits) not /21.
Common Pitfalls:
Mixing classful boundaries with CIDR math, miscounting bits in 248 (it is 11111000, five ones), or forgetting to subtract the network and broadcast addresses. Always recompute from the mask bits to avoid class-based confusion.
Final Answer:
2,046
Discussion & Comments