Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR C

java Node

import java.util.*;

public class SinglyLinkedList<E> {

    private class Node<E> {
        private E element;
        private Node<E> next;

        public Node(E e, Node<E> n) {
            element = e;
            next = n;
        }

        public E getElement() { 
            return element; 
        }

        public Node<E> getNext() { 
            return next; 
        }

        public void setNext(Node<E> n) { 
            next = n; 
        }
    } 
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #java
ADD COMMENT
Topic
Name
2+5 =