updated linked List with destructor