public void addToEnd () { Node anotherNode = new Node (currentDataValue); currentDataValue += 10; Node temp; if (isEmpty() == true) { head = anotherNode; length++; } else { temp = head; while (temp.next != null) { temp = temp.next; } temp.next = anotherNode; length++; } }