GATE CSE CIDR Notation PYQs
In GATE CS, CIDR notation is tested as a core network-layer mechanism combining binary arithmetic, bitwise masking, and address boundary alignment. Questions pr… Read the guide
- Questions
- 7
- Asked
- since 2022
- Total marks
- 13
- Marks / paper
- 0.5
7 GATE CSE CIDR Notation PYQs with solutions, from Computer Networks. Browse all GATE CSE PYQs.
Questions
Every official paper that asked this topic, newest first.
- GATE CSE 2026 Set 1 · Q56An ISP having an address block 202.16.0.0/15 assigns a block of 6000 IP addresses to a client, using the classless internet domain routing (CIDR) super-netting approach. Which of the following address blocks can be assigned by the ISP?MSQ2 marksMediumSolve
- GATE CSE 2026 Set 2 · Q33If an IP network uses a subnet mask of 255.255.240.0, the maximum number of IP addresses that can be assigned to network interfaces is __________. (answer in integer)NAT1 markEasySolve
- GATE CSE 2025 Set 1 · Q40A packet with the destination IP address arrives at a router whose routing table is shown. Which interface will the packet be forwarded to?MCQ2 marksMediumDiagramSolve
- GATE CSE 2024 Set 1 · Q58Consider the entries shown below in the forwarding table of an IP router. Each entry consists of an IP prefix and the corresponding next hop router for packets whose destination IP address matches the prefix. The notation “/N” in a prefix indicates a subnet mask with the most significant N bits set to 1. This router…NAT2 marksMediumDiagramSolve
- GATE CSE 2024 Set 2 · Q38Which one of the following CIDR prefixes exactly represents the range of IP addresses 10.12.2.0 to 10.12.3.255?MCQ2 marksEasySolve
- GATE CSE 2023 · Q65The forwarding table of a router is shown below. A packet addressed to a destination address arrives at the router. It will be forwarded to the interface with ID _________.NAT2 marksMediumDiagramSolve
- GATE CSE 2022 · Q55Consider routing table of an organization’s router shown below: Which of the following prefixes in CIDR notation can be collectively used to correctly aggregate all of the subnets in the routing table?MSQ2 marksMediumDiagramSolve
What GATE tests in CIDR Notation
Concepts, patterns, formulas and traps distilled from past papers.
In GATE CS, CIDR notation is tested as a core network-layer mechanism combining binary arithmetic, bitwise masking, and address boundary alignment. Questions predominantly evaluate Longest Prefix Match (LPM) packet forwarding across routing tables, route aggregation/supernetting validity, and host capacity calculations. Recent years emphasize Multi-Select Questions (MSQs) and numerical calculations (NATs) requiring rigorous validation of power-of-two block alignments.
Core concepts
- CIDR prefix notation (/n) and dotted-decimal subnet masks
- Longest Prefix Match (LPM) algorithm for IP forwarding
- Power-of-two block sizing and start address alignment constraints
- Route aggregation / Supernetting
- Host bit allocation vs. Network bit allocation
- Reserved IP addresses (Network ID and Directed Broadcast ID)
- CIDR notation (/n format)
- Subnet masking and bitwise AND operation
- Binary conversion of specific octets
- Longest Prefix Match (LPM) routing algorithm
- Router interface forwarding lookup
Recurring question patterns
Longest Prefix Match (LPM) Routing Table Lookup
CommonNAT2 marks2024, 2023Given a router forwarding table with multiple CIDR prefixes and interfaces/next-hop routers, determine which interface or router handles a specific destination IP (or compute aggregate packet counts across multiple host destination IPs).
CIDR Block Aggregation and Supernetting
CommonMSQ2 marks2026, 2022Given a collection of subnet routes or an ISP address pool with client capacity requirements, determine the valid CIDR prefix(es) that aggregate subnets or represent valid assignable sub-blocks conforming to boundary alignment rules.
Exact Prefix Representation of IP Range
OccasionalMCQ2 marks2024Given a contiguous range of IP addresses (start and end addresses), compute the required host bits and prefix length to find the single matching CIDR prefix.
Assignable Interface/Host Address Calculation
OccasionalNAT1 marks2026Given a subnet mask in dotted-decimal notation, compute the number of host bits and find the maximum usable host addresses after subtracting network and directed broadcast addresses.
Router Forwarding via Longest Prefix Match (LPM)
CommonMCQ2 marks2025Given a destination IPv4 address and a routing table with multiple network prefixes in CIDR slash notation (e.g., /16, /17, /18, /24) and associated interface names, determine the correct egress interface by finding all matching subnets and selecting the one with the maximum prefix length.
Formulas GATE uses
Prefix Length Calculation
Used to find CIDR mask /n when given a required address block size or number of host bits .
Assignable Host Addresses
Used when calculating valid assignable network interface IP addresses for a subnet with host bits.
CIDR Block Boundary Alignment Rule
Used to check whether a given network base IP address is a valid power-of-two CIDR boundary for block size .
Bitwise Subnet Matching
Used for each entry in a routing table during LPM evaluation before picking the longest matching prefix.
Bitwise Subnet Masking
Used to check whether a destination IP address falls within a given CIDR network prefix.
Longest Prefix Match Rule
Used to choose the winning routing table entry when more than one prefix matches the destination IP address.
Examiner traps in CIDR Notation
- Picking an aggregation prefix with correct total size but invalid boundary alignment (e.g., trying to use /21 starting at 164 where 164 is not divisible by 8).
- Stopping at the first matching prefix instead of checking all entries to find the longest matching prefix length.
- Forgetting to subtract 2 for network address and broadcast address when asked for assignable interface/host addresses.
- Applying bitwise AND on decimal octets directly instead of binary bitwise AND.
- Failing to multiply by packet counts when evaluating multi-host routing distribution NAT problems.
- Stopping at the first matching entry (e.g., choosing a shorter prefix like /16 before evaluating longer valid prefixes like /18).
- Errors in decimal-to-binary conversion for the dividing octet (e.g., converting 109 as 01101101 vs 64 as 01000000).
- Assuming higher numbered interfaces or default routes without verifying exact prefix overlap.
How questions are asked
- Routing table interface lookup via LPM
- Multi-host packet distribution count (NAT)
- Contiguous IP range to CIDR prefix mapping
- ISP address allocation validity under block boundary constraints (MSQ)
- Subnet aggregation set identification (MSQ)
- Usable host address count from subnet mask
- Identify egress interface from a routing table for a given destination IP
Paper trends
Shift from basic 1-mark single-rule lookups to multi-packet counting and multi-option verification (MSQ) testing boundary alignment.
2026, 2024, 2022
Increased use of NAT and MSQ formats over standard MCQs to test precise bitwise evaluation without reliance on option elimination.
2026, 2024, 2023
Recent examinations continue to emphasize binary-level prefix matching where multiple routing table entries match the destination IP, testing whether candidates properly apply the Longest Prefix Match rule rather than picking the first matching route.
2025
Difficulty notes
Easy items involve direct 1-step calculations such as counting assignable hosts from a mask (2^h - 2) or converting a simple contiguous 2-block range to /23. Medium items require evaluating multiple destination IPs across 4+ routing entries (LPM) or checking multiple MSQ options against both boundary divisibility constraints and allocation boundaries within an ISP pool.