Loop invariant

loop the linked list, if the node.val equals to the current.val ignore it, append it to the final linked list otherwise.