Computer Sciences > GATE 2024 Set-2 > Networking
Which one of the following CIDR prefixes exactly represents the range of IP addresses from 10.12.2.0 to 10.12.3.255?
A
10.12.2.0/23
B
10.12.2.0/22
C
10.12.3.0/23
D
10.12.3.0/24

Correct : a

To determine which CIDR prefix exactly represents the given range of IP addresses, let us convert the changing portions of the IP addresses into binary form.
1. Analyze the Constant and Changing Octets: Looking at the start and end of the address block:
• Start IP: 10.12.2.0
• End IP: 10.12.3.255

The first two octets (10.12) remain completely constant across the entire range. Since each octet represents 8 bits, this gives us 16 matching network bits right away.
2. Convert the 3rd Octet to Binary: Let us look at the binary structure of the 3rd octet for the boundary values:
• Decimal 2 in binary: 0 0 0 0 0 0 1 0
• Decimal 3 in binary: 0 0 0 0 0 0 1 1
Let's align them to find the matching network prefix length:

1st & 2nd Octet       3rd Octet
10 . 12        .  0 0 0 0 0 0 1 0  (For 10.12.2.0)
10 . 12        .  0 0 0 0 0 0 1 1  (For 10.12.3.255)
---------------------------------
<- 16 bits ->  <-   7 bits   -> -> The first 7 bits match perfectly.
Counting the total number of identical, continuous bits from left to right:
• First two octets = 16 bits
• Third octet matching bits = 7 bits
• Total network prefix length = 16 + 7 = 23 bits.
3. Determine the Network Address: The common prefix up to the 23rd bit gives us the base network address. Setting all remaining host bits (the last bit of the 3rd octet and all 8 bits of the 4th octet) to 0 results in:
• 3rd Octet: 00000010 → 2
• 4th Octet: 00000000 → 0

This creates the full CIDR identifier: 10.12.2.0/23.
4. Verify Total Addresses: A /23 network leaves $32 - 23 = 9$ bits for host allocation.
The total number of addresses in this block is $2^9 = 512$.
Our target range spans from 10.12.2.0 to 10.12.3.255, which contains exactly 256 addresses from the .2 block and 256 addresses from the .3 block ($256 + 256 = 512$). This confirms the block calculation is correct.
Conclusion: The prefix that exactly matches the address block is 10.12.2.0/23, corresponding to option (a).

Similar Questions

In an Ethernet local area network, which one of the following statements is TRUE ?
#99 MCQ
Consider a network connecting two systems located 8000 kilometers apart. The bandwidth of the network is 500 × 106 bits per second. The propagation speed of the...
#521 Fill in the Blanks
Which of the following fields is/are modified in the IP header of a packet going out of a network address translation (NAT) device from an internal network to a...
#867 MSQ

Related Topics

No tags found

Unique Visitor Count

Total Unique Visitors

Loading......