How to cancel a cd command in a terminal in Mac OS X?

I am starting to learn Ruby and follow the instructions of a single video to access the desktop via the -ls command in the terminal. Now I would like to exit the desktop in the terminal and do not know how to do this. I know, I know that I'm a complete noob ... but someone can help. Thank you By the way, the command I wrote was:

my-iMac~ me$ cd Desktop/ my-iMac:Desktop samuel$ ls 
+7
source share
2 answers

Where would you like to go?

Go home: cd or cd ~
Change to the previous working directory: cd $OLDPWD
Browse to the parent directory of the current directory: cd ..
Change to any directory: cd /path/to/directory

+21
source

cd .. will return you 1 level.

+5
source

All Articles