From Mac Guides
cd is a command used to set the current directory. The current directory is the directory which file paths you enter are relative to. For example, if the current directory was "~/Library/" and you entered as a parameter to a command "Preferences", it would treat it as if you had typed "~/Library/Preferences". Commands that have an optional file path parameter, such as ls, will often use the current directory if none is specified.
The current directory is displayed in the command prompt, as follows
Where Computer-Name is the name of your computer and username is your current username.
Reset the current directory to your home folder (the default)
Set the current directory to the Applications folder
Man Page Excerpt
Change the current working directory to dirName, or to the home directory (as specified in the HOME environment variable) if dirName is not given. Returns an empty string.