Note: (Restricted functionality due to obvious reasons!)

For Mobile-Ease ⇓

Minimal Code ( Raw-View ) :
import java.util.*; class ListDemo { public static void main(String zee[]) { List l = new ArrayList(); //Interface[Set] variable[s] = new ImplementationClass[HashSet]{of Interface-Set] l.add("Deepak"); // m.put(key, value) l.add("Abhi"); l.add("John"); l.add("In"); l.add("List"); l.add("Stored"); l.add("as"); l.add("Inserted"); Iterator itr = l.iterator(); while(itr.hasNext()) { String str = (String)itr.next(); System.out.println(str); } } }