Complete the code to identify the field that holds the source port number in a TCP segment.
The first 16 bits of a TCP segment represent the [1].
The first 16 bits in a TCP segment header specify the source port number, which identifies the sending application.
Complete the code to identify the size of the TCP header length field.
The TCP header length field is [1] bits long.The TCP header length field is 4 bits long and indicates the size of the TCP header in 32-bit words.
Fix the error in the statement about the TCP flags field size.
The TCP flags field is [1] bits long.The TCP flags field is 9 bits long, including flags like SYN, ACK, FIN, and others.
Fill both blanks to complete the description of the TCP checksum and urgent pointer fields.
The TCP checksum field is [1] bits long and is followed by the urgent pointer field which is [2] bits long.
Both the TCP checksum and urgent pointer fields are 16 bits long each.
Fill all three blanks to complete the dictionary comprehension that maps TCP header fields to their sizes in bits, filtering only fields larger than 16 bits.
tcp_fields = {"[1]": [2], "[3]": 32, "window": 16, "checksum": 16}
large_fields = {field: size for field, size in tcp_fields.items() if size > 16}The sequence number and acknowledgment number fields are 32 bits each, so they are included in the filtered dictionary.