CS FundamentalsVery hardGATE CS
A router has routes for the following prefixes, all pointing to the same next hop: 172.16.0.0/24, 172.16.1.0/24, 172.16.2.0/24, 172.16.3.0/25, 172.16.3.128/26, 172.16.3.192/26, 172.16.4.0/23, 172.16.6.0/24, 172.16.7.0/24, 172.16.8.0/22, 172.16.12.0/23, 172.16.14.0/24 and 172.16.15.128/25. What is the minimum number of prefixes needed to represent exactly the same set of addresses?
- A. 6
- B. 5
- C. 4
- D. 8
Correct answer: B. 5
Merging only exactly adjacent, aligned blocks gives ['172.16.0.0/21', '172.16.8.0/22', '172.16.12.0/23', '172.16.14.0/24', '172.16.15.128/25'], i.e. 5 prefixes. The first eight /24 blocks merge into 172.16.0.0/21, but 172.16.8.0/22, 172.16.12.0/23, 172.16.14.0/24 and 172.16.15.128/25 cannot merge further because 172.16.15.0/25 is missing.
More Computer Networks questions
- A 16-bit Internet checksum is computed over the five 16-bit words 4A3F, B7C1, 2E9D, F05A and 8C13 (hexadecimal): the words are added with…
- A 4-port learning switch has an empty MAC table. Hosts A, B, E, C and D are attached as follows: A and F on port 1 (through a hub), B and…
- A stop-and-wait link carries 1000-byte frames at 2 Mbps with a one-way propagation delay of 20 ms; ACK transmission time is negligible…
- A token bucket has capacity 3 MB, a token arrival rate of 6 MB/s, and starts full. The link allows a maximum output rate of 30 MB/s. For…
- A single-error-correcting Hamming code protects m data bits with r check bits satisfying 2^r >= m + r + 1. How many check bits are needed…
- A 12-bit CRC uses a generator polynomial of degree 12 with non-zero constant term. What are the probabilities that a burst error of length…