Choose the correct expression from the following for the length of UDP datagram.
2021
Choose the correct expression from the following for the length of UDP datagram.
- A.
UDP length = IP length – IP header’s length
- B.
UDP length = UDP length – UDP header’s length
- C.
UDP length = UDP length – UDP header’s length
- D.
UDP length = UDP length + UDP header’s length
- E.
Question not attempted
Attempted by 157 students.
Show answer & explanation
Correct answer: A
To determine the length of a UDP datagram, we start with the total length of the IP packet, which includes the IP header and the payload. The payload contains the UDP header and the UDP data. Therefore, the UDP length can be calculated by subtracting the IP header length from the total IP length. This gives the length of the UDP datagram, including the UDP header.