Computer Science Engineering (CSE) Exam  >  Computer Science Engineering (CSE) Test  >  GATE Computer Science Engineering(CSE) 2027 Mock Test Series  >  Test: Introduction & IP Addressing- 1 - Computer Science Engineering (CSE) MCQ

GATE Computer Science Engineering(CSE) 2027 Test: Introduction & IP Addressing


MCQ Practice Test & Solutions: Test: Introduction & IP Addressing- 1 (10 Questions)

You can prepare effectively for Computer Science Engineering (CSE) GATE Computer Science Engineering(CSE) 2027 Mock Test Series with this dedicated MCQ Practice Test (available with solutions) on the important topic of "Test: Introduction & IP Addressing- 1". These 10 questions have been designed by the experts with the latest curriculum of Computer Science Engineering (CSE) 2026, to help you master the concept.

Test Highlights:

  • - Format: Multiple Choice Questions (MCQ)
  • - Duration: 30 minutes
  • - Number of Questions: 10

Sign up on EduRev for free to attempt this test and track your preparation progress.

Test: Introduction & IP Addressing- 1 - Question 1

Class ‘C’ IP addresses use ______ bits for Network ID.

Detailed Solution: Question 1

In class A, 24 bits are reserved for Host Id and 8 bits are reserved for Network Id.

In class B, 16 bits are reserved for Host Id and 16 bits are reserved for Network Id.

In class C, 8 bits are reserved for Host Id and 24 bits are reserved for Network Id.

Test: Introduction & IP Addressing- 1 - Question 2

You are working with a network that is 172.16.0.0 and would like to support 600 hosts per subnet. What subnet mask should you use?

Detailed Solution: Question 2

Concept:

In class B, the first two octets(16 bits) represent network address and out of these 16 bits first two bits are fixed(10) to specify that its class B and the remaining 14 bits represent 214 networks, and each network has 216 - 2 host.

So,

IPv4 address: 32 bits

Network Id = 16 bits

Since there are 600 Host ID

∴ Host ID = ⌈log600⌉= 10

IP address = Network ID + Subnet ID + Host ID

32 = 16 + Subnet ID + 10

∴ Subnet ID = 6

In subnet mask, all host id bits are 0 and network id, subnet id are 1’s

Network ID + Subnet ID = 6 + 16 = 22 bits

subnet mask: 11111111. 11111111. 11111100.00000000

subnet mask: 255. 255.252.0

Test: Introduction & IP Addressing- 1 - Question 3

An IPv4 address is a __________ address, which is categorised into different IP classes.

Detailed Solution: Question 3

IP address is an address having information about how to reach a specific host. The 32 bit IP address is divided into five sub classes. These are:

1) Class A

2) Class B

3) Class C

4) Class D

5) Class E

Class D and E are reserved for multicast and experimental purposes.

IPv4 address:

An IPv4 address is a 32 bits address, which is categorized into different IP classes.

IPv4 addresses are divided into two parts: a) Network ID b) Host ID

Class A: This class uses 8 bits for network ID part and 24 bit for host ID.

Class B: This class uses 16 bits for network ID and 16 bits for host ID.

Class C: This class uses 24 bits for network ID and 8 bits for host ID.

Test: Introduction & IP Addressing- 1 - Question 4

Match List - I with List - II.

Choose the correct answer from the options given below:

Detailed Solution: Question 4

The correct answer is A - III, B - IV, C - II, D - I

10.20.30.40 (A):

  • This IP address falls within the range of 1.0.0.0 to 126.0.0.0, which is designated for Class A. So, A matches with III.

210.20.30.3 (B):

  • This IP address falls within the range of 192.0.1.0 to 223.255.254.0, which is designated for Class C. So, B matches with IV.

180.30.100.10 (C):

  • This IP address falls within the range of 128.1.0.0 to 191.255.0.0, which is designated for Class B. So, C matches with II.

252.5.15.11 (D):

  • This IP address falls within the range of 240.0.0.0 to 255.255.255.255, which is designated for Class E. So, D matches with I.

Therefore, the correct option is A - III, B - IV, C - II, D - I. So, the correct option is 4).

Test: Introduction & IP Addressing- 1 - Question 5

The IP address _______ is used by hosts when they are being booted.

Detailed Solution: Question 5

The correct answer is option A.
In IPv4 0.0.0.0 is used for the default route. IP address 0.0.0.0 is used by hosts when they are being booted. If the packet's destination address is unknown, and the default route is unknown, but the default route is present in the router's routing table, the packet is not discarded but forwarded to the next router.
∴ Hence the correct answer is 0.0.0.0.

Test: Introduction & IP Addressing- 1 - Question 6

The IP address is _______ bits in length.

Detailed Solution: Question 6

IP address:

IP address is an address having information about how to reach a specific host. The 32 bit IP address is divided into five sub classes. These are:

1) Class A

2) Class B

3) Class C

4) Class D

5) Class E

Class D and E are reserved for multicast and experimental purposes.

IPv4 address:

An IPv4 address is a 32 bits address, which is categorized into different IP classes.

IPv4 addresses are divided into two parts: a) Network ID b) Host ID

Class A: This class uses 24 bits for network ID part and 8 bit for host ID.

Class B: This class uses 16 bits for network ID and 16 bits for host ID.

Class C: This class uses 8 bits for network ID and 16 bits for host ID.

Note: IPv6 is a128 bits address

Test: Introduction & IP Addressing- 1 - Question 7

In the IPv4 addressing format, the number of networks allowed under Class C addresses is 

Detailed Solution: Question 7

IPv4 address: 32 bits

IP address = Network ID + Host ID

Network ID + Host ID =32

PREFIX is the part of the Network ID

Test: Introduction & IP Addressing- 1 - Question 8

An IP packet has arrived with the first 8 bits as 0100 0010. Which of the following is correct ?

Detailed Solution: Question 8

Concept

Minimum header size of IPv4 = 20 byte

Maximum header size of IPv4 = 60 byte

Header length field in the IPv4 header is 4 bits.

Maximum possible value (1111) = 15

The scaling factor of 6015=4 is introduced

IP header

 

But the first 8 bits in the Question are 0100 0010.

The first 4 bits indicate the version which is IPv4 (0100)

Now the next four bit indicates Header length (bits decimal value × 4) which is 2 × 4 = 8 bytes

which is not possible since the minimum header length for IPv4 is 20 bytes.

Hence Receiver will reject the packet.

Therefore option D is the correct answer.

Test: Introduction & IP Addressing- 1 - Question 9

Two computers A and B are configured as follows: A has IP address 203.197.2.53 and subnet mask 255.255.128.0, B has IP address 203.197.75.201 and subnet mask 255.255.192.0. What one of the following statement is true?

Detailed Solution: Question 9

The correct answer is A assumes, B is on same network, but B assumes, A is on a different network

Given Information:

  • Computer A:
    • IP Address: 203.197.2.53
    • Subnet Mask: 255.255.128.0
  • Computer B:
    • IP Address: 203.197.75.201
    • Subnet Mask: 255.255.192.0

Step 1: Calculate the Network Address for A

1. Convert the Subnet Mask to Binary:

  • Subnet Mask A: 255.255.128.0 
  • In binary: 11111111.11111111.10000000.00000000

2. Convert the IP Address to Binary:

  • IP Address A: 203.197.2.53 
  • In binary: 11001011.11000101.00000010.00110101

3. Perform Bitwise AND:

  • Network Address A:
    qImage6706303006c721a46f0dffaf

Step 2: Calculate the Network Address for B

1. Convert the Subnet Mask to Binary:

  • Subnet Mask B: 255.255.192.0
  • In binary: 11111111.11111111.11000000.00000000

2. Convert the IP Address to Binary:

  • IP Address B: 203.197.75.201 
  • In binary: 11001011.11000101.01001011.11001001

​3. Perform Bitwise AND:

  • Network Address B:
    qImage6706303106c721a46f0dffcc

Summary of Network Addresses:

  • Network Address A: 203.197.0.0
  • Network Address B: 203.197.64.0

Step 3: Determine Network Assumptions

  • For Computer A (203.197.2.53):
    • It calculates its network address as 203.197.0.0.
    • It considers Computer B (203.197.75.201) as being on the same network if the IP falls within the same network address range.
  • For Computer B (203.197.75.201):
    • It calculates its network address as 203.197.64.0.
    • Since 203.197.2.53 does not fall within the range of 203.197.64.0, it assumes that A is on a different network.

Conclusion

  • Computer A assumes that Computer B is on the same network.
  • Computer B assumes that Computer A is on a different network.

Thus, the correct option is indeed: c) A assumes B is on the same network, but B assumes A is on a different network.

Test: Introduction & IP Addressing- 1 - Question 10

What flavour of Network Address Translation can be used to have one IP address allow many users to connect to the global internet?

Detailed Solution: Question 10

PAT (Port Address Translation):

  • Allows a one to many approaches to network address translation (NAT)
  • Permits multiple devices on a LAN to be mapped to a single public IP address.
  • Goal of PAT is to conserve IP address
  • Most home networks use PAT.
  • Thousands of users can be connected to the internet by using one public address.

Static NAT:

  • A single private IP address is mapped with single public IP address.
  • Used in web hosting.
  • Private IP address is translated to a public IP address.

Dynamic NAT:

  • Multiple private IP address are mapped to a pool of public IP address.
  • Used when we know the number of fixed user wants to access the internet at any time.

So,
From above concepts we can say that PAT is used can be used to have one IP address allow many users to connect to the global internet.

56 docs|215 tests
Information about Test: Introduction & IP Addressing- 1 Page
In this test you can find the Exam questions for Test: Introduction & IP Addressing- 1 solved & explained in the simplest way possible. Besides giving Questions and answers for Test: Introduction & IP Addressing- 1, EduRev gives you an ample number of Online tests for practice
Download as PDF