In ksh , a shell veriable $$ contains the id of the current process .
So ,
kill $$
will kill the currecnt process , which generally does not look like a logical task .
If u want to kill some perticular process ,
ps -e -o "%p %y %a"
will give u only the process id , terminal name and process description . grep or with some logic select your processes to be killed and then use the id to kill processes .