a bug in the linked list, when the head was remove the next node didn't knew that his predecessor was empty