// Hunter Schafer, CSE 143 // Represents a single node of a linked list public class ListNode { public int data; public ListNode next; // Constructs a ListNode containing the given data public ListNode(int data) { this(data, null); } // Constructs a ListNode containing the given data and // references the given next public ListNode(int data, ListNode next) { this.data = data; this.next = next; } }