In a job interview I was asked, what are the 2 slashes for in a URL address. I did not know and cannot find something about it.
http://stackoverflow.com
In a job interview I was asked, what are the 2 slashes for in a URL address. I did not know and cannot find something about it.
http://stackoverflow.com
Try reading this link http://en.wikipedia.org/wiki/Uniform_resource_locator and http://en.wikipedia.org/wiki/URI_scheme#Generic_syntax
The scheme name consists of a sequence of characters beginning with a letter and followed by any combination of letters, digits, plus ("+"), period ("."), or hyphen ("-"). Although schemes are case-insensitive, the canonical form is lowercase and documents that specify schemes must do so with lowercase letters. It is followed by a colon (":").
The hierarchical part of the URI is intended to hold identification information hierarchical in nature. If this part begins with a double forward slash ("//"), it is followed by an authority part and a path. If the hierarchical part doesn't begin with ("//") it contains only a path.
The authority part holds an optional user-information part, terminated with "@" (e.g. username:password@); a hostname (e.g., domain name or IP address); and an optional port number, preceded by a colon ":". The path part, if present, may optionally begin with a single forward slash ("/"). It may not begin with two slash characters ("//"). The path is a sequence of segments (conceptually similar to directories, though not necessarily representing them) separated by a forward slash ("/").
Historically, each segment was specified to contain parameters separated from it using a semicolon (";"), though this was rarely used in practice and current specifications allow but no longer specify such semantics.