3. [6 marks] Identify the components of this URL and their meaning:
	http://www.cdf.toronto.edu/~c5fred/moths/overview.html

Sample solution:

(you did not have to write nearly this much)

"http" indicates the protocol your web browser should use to retrieve the web page, and also the "scheme" for the URL. Some of the rest of this answer is specific to the "http" scheme.

The colon-slash-slash separates the scheme name from the hostname.

"www.cdf.toronto.edu" is the hostname. This name is looked up in DNS to get the IP address 128.100.31.101. Your web browser makes a connection to 128.100.31.101. (This hostname's components can be further-analyzed themselves.)

"/~c5fred/moths/overview.html" is the path name passed to the web server by your web browser. This also can be further-analyzed: The first component means to look for a public_html subdirectory in c5fred's account. "moths" would be a subdirectory of that. Inside that subdirectory, the web server would find the file "overview.html", and that's the file which would be transmitted to the web browser user.


(press 'back' in your web browser to get back to where you were in the exam)