Belajar Perulangan NetBeans IDE 8.0.2
Langkah-langkahnya:
1. Buka Dulu NetBeans IDE 8.0.2
2. Klik New Projek
3.
Berikut Codingan nya Teman-teman:
package nilai;
public class Nilai {
public static void main(String[] args) {
int i,j,k;
//perlungan for
for (i=1; i<10; i++){
System.out.print(i + "--------FOR--------");
}
System.out.println();
//pengulangan while
j=1;
while(j<10){
System.out.println(j + "--------WHILE-------- ");
j++;
}
System.out.println();
//pengulangan do while;
k=1;
do{
System.out.println(k + "--------DO WHILE--------");
k++;
}while(k<10);
}
}
1. Buka Dulu NetBeans IDE 8.0.2
2. Klik New Projek
3.
4.
Berikut Codingan nya Teman-teman:
package nilai;
public class Nilai {
public static void main(String[] args) {
int i,j,k;
//perlungan for
for (i=1; i<10; i++){
System.out.print(i + "--------FOR--------");
}
System.out.println();
//pengulangan while
j=1;
while(j<10){
System.out.println(j + "--------WHILE-------- ");
j++;
}
System.out.println();
//pengulangan do while;
k=1;
do{
System.out.println(k + "--------DO WHILE--------");
k++;
}while(k<10);
}
}
0 Response to "Belajar Perulangan NetBeans IDE 8.0.2"
Post a Comment
Silahkan Komentar ....