Update reversely output values of linked list.java