「Java8入門」for文で繰り返し処理のサンプル
Javaコード:
package sample;
public class Dccr {
public static void main(String[] args) {
String []cft = {“data1″,"data2″,"data3″,"data4"};
System.out.println(“output message:");
for(String val:cft){
System.out.println(val);
}
}
}
結果
output message:
data1
data2
data3
data4