StringVectorExampleII - /Line 5...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
//StringVectorExample / import java.util.Vector; i public class StringVectorExampleII { public static void main(String[] arg) { Vector<String> stringList = new Vector<String>(); //Line 1 stringList.addElement("One"); //Line 2 stringList.addElement("Two"); //Line 3 stringList.addElement("Three"); //Line 4 stringList.addElement("Four");
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: //Line 5 stringList.addElement("Five"); //Line 6 stringList.addElement("Six"); //Line 5 stringList.addElement("Seven"); //Line 6 System.out.println("stringList: " + stringList); //Line 7 for (String str : stringList) //Line 8 System.out.println(str.toUpperCase()); //Line 9 } }...
View Full Document

This note was uploaded on 06/17/2011 for the course COMP 2301 taught by Professor Staff during the Spring '10 term at Kennesaw.

Ask a homework question - tutors are online