Modifying the /etc/hosts file in Percise Pangolin

I would like to modify my hosts file to block a list of adservers with the 127.0.0.1 address,
This is what I have done but I have not been sucessfull yet in saving the new file or getting it installed properly
.
I typed

Code:

sudo vi /etc/hosts
# You'll be prompted for your account password
# Press the down arrow past any # comments to get to the list of hosts
i
# pressing i puts you into insert mode
# press return and up arrow to create a blank line
128.117.224.210 www.scd.ucar.edu
# press the escape key
:wq!
sudo killall -HUP lookupd

I pressed the escape key and it did not let me escape. and I didnot get the $ to enter the last command " sudo killall

Any assistance on this issue. I did not see much in the way of this on the board.