package com.myapp.test;
public class ForEachTest {
public static void main(String[] args) {
String[] lastName = new String[5];
lastName[0] = "Winklemann";
lastName[1] = "Ruiz";
lastName[2] = "Gandhi";
lastName[3] = "Yakazuki";
lastName[4] = "Jones";
for (String thisName : lastName) {
System.out.println("Nameis " + thisName);
}
}
}
public class ForEachTest {
public static void main(String[] args) {
String[] lastName = new String[5];
lastName[0] = "Winklemann";
lastName[1] = "Ruiz";
lastName[2] = "Gandhi";
lastName[3] = "Yakazuki";
lastName[4] = "Jones";
for (String thisName : lastName) {
System.out.println("Nameis " + thisName);
}
}
}