in pset6 specification, to make request to server, the port no. of the server is noted and included with the ip address of the appliance like http://#.#.#.#.####/cat.jpg. The port no. of the server is required but then why are we specifying http in beginning.
according to Wikipedia:
In computer networking, a port is a software construct serving as a communications endpoint in a computer's host operating system.
when you execute
./server -p <port> <root>
where <port>
is a valid port number, you're setting the server to listen to HTTP requests on the port with that number.
if you don't specify port number in the URL, it's gonna be 80 by default in which case if your server isn't listening to HTTP requests on that port, they won't be processed.
also the port number should be preceded with a colon. for example
http://w.x.y.z:port/foo.html
and we're specifying http
in the beginning because that's the protocol that we are using to request files from the server.