Consider three machines M, N, and P with IP addresses , and respectively. The subnet mask is set to for all the three machines. Which one of the following is true?
View worked solution
Answer: C
To determine which machines belong to the same subnet, we perform a bitwise AND operation between each machine's IP address and the subnet mask, or simply analyze the block sizes determined by the mask.
1. Analyze the Subnet Mask
The subnet mask is given as 255.255.255.252.
- The first three octets (
255.255.255) are identical for all three machines, so we only need to examine the last octet. - The last octet of the mask is , which in binary is .
- The number of host bits in the last octet is bits.
- This gives a block size (subnet size) of IP addresses per subnet.
2. Determine the Subnet Ranges
Since the block size is , the subnets for the last octet start at multiples of :
- Subnet 1: to (Network ID:
100.10.5.0, Broadcast:100.10.5.3) - Subnet 2: to (Network ID:
100.10.5.4, Broadcast:100.10.5.7) - Subnet 3: to (Network ID:
100.10.5.8, Broadcast:100.10.5.11)
3. Map the Machines to Subnets
- Machine M: IP
100.10.5.2(Last octet is ). It falls in the range , so its subnet ID is100.10.5.0. - Machine N: IP
100.10.5.5(Last octet is ). It falls in the range , so its subnet ID is100.10.5.4. - Machine P: IP
100.10.5.6(Last octet is ). It falls in the range , so its subnet ID is100.10.5.4.
Thus, only N and P belong to the same subnet (100.10.5.4/30).
Free practice · Your answers on this page are not saved.
