File comparision

Hi All
I have to files

cat a.txt
AAA
BBB
CCC
DDD

and

cat b.txt
AAA
CCC
EEE

i want to compare these two files and o/p should have content of file a.txt which is not in file b.txt

c.txt 
BBB
DDD 

Please help me

Try this ,

diff a.txt  b.txt  | grep "^<" | sed -r "s/< (.+)/\1/g" >c.txt

See the man page of man grep (POSIX):

$ grep -vf b.txt a.txt
BBB
DDD

Try this,

comm -13 b.txt a.txt >c.txt