implemented a remove function
some test for the remove function