GateAI
CIDR Notation

GATE CSE 2026 Set 2 · Q33

NAT1 markEasy

Time

If 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)

Your answerNumerical answer

Enter a value to check

Solution

Step-by-step verified solution

Official answer: 4094

CIDR Notation

To find the maximum number of assignable IP addresses for network interfaces (hosts):

  1. Convert the subnet mask to binary:

    255.255.240.0=11111111.11111111.11110000.00000000\text{255.255.240.0} = 11111111.11111111.11110000.00000000
  2. Count the network and host bits:

    • Number of prefix (network/subnet) bits n=8+8+4=20n = 8 + 8 + 4 = 20

    • Number of host bits h=32−20=12h = 32 - 20 = 12

  3. Calculate total and assignable host addresses:

    • Total IP addresses in this subnet =2h=212=4096= 2^h = 2^{12} = 4096

    • Two addresses are reserved in standard IPv4 subnetting:

      • Network address (all host bits are 00)

      • Directed broadcast address (all host bits are 11)

    Assignable IP addresses=212−2=4096−2=4094\text{Assignable IP addresses} = 2^{12} - 2 = 4096 - 2 = 4094

Thus, the maximum number of IP addresses that can be assigned to network interfaces is 4094.

Try the question first, then check your work.

Think the official key or this write-up is wrong?

Report error or challenge

Examiner trap

The misconception this question tests

This CIDR Notation previous year question is Q33 of the GATE CSE 2026 Set 2 paper. Find more GATE CSE PYQs on CIDR Notation in Computer Networks, or browse all GATE CSE PYQs.

Free diagnostic

Where do you stand for GATE?

Take the 20-minute diagnostic: the 3 topics that cost you the most marks, and a rank range. Or sit 5 related CIDR Notation PYQs now with no account.

One GATE CSE PYQ every morning

An official question by email at 7 AM IST, with a link to its verified solution. Unsubscribe in one click.

CIDR Notation in GATE CSE

CIDR Notation has 7 GATE CSE PYQs across 7 papers from 2022 to 2026. This is the only 1-mark NAT question among them, and it is the only one in GATE CSE 2026 Set 2.

How GATE tests CIDR Notation

More from GATE CSE 2026 Set 2

Share this solution

A plain-text card for WhatsApp or Telegram study groups.

GateAI solution cardGATE CSE 2026 Set 2 · Q33 · NAT

If 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)

Topic-wise GATE CS PYQs with verified steps

Independent practice explanation verified by the GateAI team. GATE is conducted by the IITs; question text follows the official paper.