implement delete.pl and other things