Examination Paper: May/June 201 9 COMP2211-WE01
Examination Paper: May/June 201 9 COMP2211-WE01
Examination Paper: May/June 201 9 COMP2211-WE01
EXAMINATION PAPER
Examination Session: Year: Exam Code:
Revision:
Page 2 of 6 COMP2211-WE01
Section A Networks
(Dr Sardar Jaf)
Question 1
(a) Define the terms “multiplexing” and “demultiplexing” that are used in the
transport layer of the layered protocol stack. [4 Marks]
(b) Suppose that a message 1001 1100 1010 0011 is transmitted using Internet
Checksum (4-bit word). What is the value of the checksum? Explain how
you arrived at your solution. [5 Marks]
(c) Identify and briefly describe two different types of Carrier Sense Access
Control Protocols. [6 Marks]
A = (-1 -1 -1 +1 +1 -1 +1 +1)
B = (-1 -1 +1 -1 +1 +1 +1 -1)
C = (-1 +1 -1 +1 +1 +1 -1 -1)
[5 Marks]
Question 2
(d) Explain how an adaptive load distribution algorithm restricts the scope of
a target server search, regardless of whether the workload of a distributed
system is high or low.
Suppose the distributed system is prone to server failure. Modify the algo-
rithm to improve the effectiveness of load distribution. [5 Marks]
(e) Describe three forward error recovery methods. Analyse which method is
the best option to support error recovery for an eBay-like online auction
system. [8 Marks]
Question 3
Question 4
X1 → X2 a | X3 c | c
X2 → X2 ca | b
X3 → X1 b | ε
[5 Marks]
(c) Lex is a software tool that automatically generates a lexical analyzer, given
a set of patterns (regular expressions) with some specific order. In par-
ticular, Lex simulates an NFA from the given patterns. It scans the input
string until it finds the longest prefix of the input that matches one of the
given patterns. If this longest prefix matches more than one pattern, then
Lex chooses among them the pattern that is first in the order.
Let the three patterns in the picture below be given to Lex (in this order).
Assuming that the input string is aabac, find the matching pattern of
Lex and the longest returned prefix. Show all intermediate steps of your
computation.
c b a
start a b,a c
1 2 3 4
a c
start a b a
5 6 7 8
a c,a
start b b
9 10 11 c 12
[7 Marks]
END OF PAPER