To close out of Emacs
C-x C-c
If you have any open buffers, it will ask you to save before closing out of Emacs.
Confused?
C-h C-h : help menu
Undo
C-x u
As you can see, Emacs has more moving parts, so the learning curve is a little steeper. In exchange, though, you get a very powerful text editor.