The Gateway to Computer Science Excellence
+6 votes

A IP packet has arrived in which the fragmentation offset value is 100,the value of HLEN is 5 and the value of total length field is 200. What is the number of the last byte?

  1. 194
  2. 394
  3. 979
  4. 1179
in Computer Networks by Active (2.5k points) | 4.6k views

4 Answers

+14 votes
Best answer
Data length=200-4*5=180

Starting number of first byte of fragment=100*8=800

Number of last byte=800+179=979

Ans c
by Boss (31.4k points)
selected by
why 179 is added could you please explain it?
coz there are 180 bytes so + 0-179  @abhishek
@ danny thanx dude..I got it
4*5 means
Someone please answer this
hlen is of 4 bits and it can represent a maximum value of 15. while the header length can g upto 60. so we use a scale factor of 4. so now 4 bits can represent upto 15*4 = 60. so if the value of hlen is 5 then it means it is actually representing 5*4 = 20. hope that clears!
why 100 is multiply by 8. Does it convert into bits?

@ pankajbelwal , scaling factor of fragment offset is 8.


@ayush palak @Raju Kalagoni    But shouldn't data be a multiple of 8? Here data size is 180, which is not a multiple of 8.


@shraddha priya, data need not be a multiple of 8. it doesn't make sense to have data always in multiple of 8. We should always be in a position to send data across network either in multiple of 8 or not.


@shraddha priya Data should be a multiple of 8 in cases where there are more than 1 fragmented packets and all the packets except the last packet must be a multiple of 8. If there is only one packet or the packet is last fragmented packet then it need not be a multiple of 8. 

+4 votes

Total Length=200

Data feild excluding header=200-20=180(0---179)

No of byte ahead from this packet is=100*8=800

so last byte =800+179=979
by Boss (10.2k points)
+3 votes


An IP packet looks like this.

Header Length = $5*4=20$

So, Payload = $200-20=180$


Fragmentation offset = $100*8=800$

The last byte would be $180 + 800$th = $980th$ but since we number everything from 0 in computer science, it'll be $979th$

by Loyal (6.3k points)
0 votes
answer is C
by Loyal (9.9k points)

Related questions

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
50,737 questions
57,275 answers
104,820 users