Computer Networks
Transport Protocols & IP Addressing
GATE 2019
Medium
Consider three machines M, N, and P with IP addresses 100.10.5.2, 100.10.5.5, and 100.10.5.6 respectively. The subnet mask is set to 255.255.255.252 for all the three machines. Which one of the following is true?
- AM, N, and P all belong to the same subnet
- BOnly M and N belong to the same subnet
- Only N and P belong to the same subnet
- DM, N, and P belong to three different subnets
Explanation
Mask 255.255.255.252 = /30, giving subnet blocks of 4 addresses each in the last octet: [0-3],[4-7],[8-11],.... M's last octet 2 falls in [0-3]; N's 5 and P's 6 both fall in [4-7]. So only N and P share a subnet.
Source: GATE CS 2019 (Set-2) (2019)
This question is part of a 15-day revision cycle — sign in and Project Forge will bring it back the day before you'd forget it.