adding insert and delete functions.