------------------------------------------------------------------------
kill
------------------------------------------------------------------------

As the name implies, "kill" deletes processes. Say you have three
terminals open 

$ ps
18881 ttys000    0:00.05 -zsh
18885 ttys001    0:00.31 -zsh
18889 ttys002    0:00.08 -zsh
19304 ttys002    0:00.14 vi kill.txt   #because I am editing kill.txt

If you want to see non-terminal processes then 
$ ps -A 
will result in a torret of output which you need to "grep".

For now let us restrict to jobs launched from terminals.

You can kill terminal ttys000 by 
$ kill -KILL 18881 	

To further illustrated kill let us launch a "leave" process

$ kill +0001	#leave in 00 hours and 01 minutes

$ ps 
18885 ttys001    0:00.37 -zsh
19380 ttys001    0:00.00 leave +0001
18889 ttys002    0:00.08 -zsh
19304 ttys002    0:00.57 vi kill.txt

The shell announces "Time to leave!!"

Let us say you ignore it. Then it will keep reminding you it is time to leave

$ ps
  PID TTY           TIME CMD
18885 ttys001    0:00.39 -zsh
19380 ttys001    0:00.00 leave +0001
18889 ttys002    0:00.08 -zsh
19304 ttys002    0:00.69 vi kill.txt

You can kill the "leave" program by kill -KILL 19380 or you can be clever and 
devise this command

$ ps | grep "leave"
19380 ttys001    0:00.00 leave +0001
19391 ttys001    0:00.00 grep leave

Now you have two processes which contain "leave".

Simple method:
$ ps | grep "leave" | grep -v "grep"
19380 ttys001    0:00.00 leave +0001

Armed thus you could execute
$ kill -KILL $(ps | grep "leave" | grep -v "grep" | awk '{print $1}')

$ ps
  PID TTY           TIME CMD
18885 ttys001    0:00.41 -zsh
18889 ttys002    0:00.08 -zsh
19304 ttys002    0:00.96 vi kill.txt

Sophisticated:
$ echo $(ps | grep "[l]eave" | awk '{print $1}')   #interesting use of regex

Utterly Simple:
$ pkill leave