second implementation on #19, deleting files