Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

list in java

import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;

public class testo {
    public static void main(String args[]){
    List<Object> list = new ArrayList<Object>();
    list.add("1");
    list.add("2");
    list.add("3");
    list.add("4");
    list.add("5");

    Iterator<Object> it = list.iterator();
    while(it.hasNext()){

        System.out.println(it.next());
    }
}
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #list #java
ADD COMMENT
Topic
Name
8+9 =