The GATE Grind

GATE 2022 CS – Question 55

Computer Networks · IPv4: Addressing, CIDR, Fragmentation and NAT · 2 marks · Multiple select

Consider routing table of an organization’s router shown below:
Subnet Number | Subnet Mask | Next Hop
12.20.164.0 | 255.255.252.0 | R1
12.20.170.0 | 255.255.254.0 | R2
12.20.168.0 | 255.255.254.0 | Interface 0
12.20.166.0 | 255.255.254.0 | Interface 1
default | | R3
Which of the following prefixes in CIDR notation can be collectively used to correctly aggregate all of the subnets in the routing table?

  1. 12.20.164.0/20
  2. 12.20.164.0/22
  3. 12.20.164.0/21
  4. 12.20.168.0/22

Practise this question in The GATE Grind →

Show answer and explanation

Correct answer: (A) 12.20.164.0/20; (C) 12.20.164.0/21

Explanation

The subnets span third-octet values 164 to 171. 12.20.164.0/21 covers exactly 164–171, and the shorter /20 prefix (160–175) also covers all of them. The /22 prefixes each cover only half the range.