import java.util.Scanner;
public class SikuKiriTerbalik {
public static void main(String[] args) {
System.out.print("Masukkan Banyak Baris: ");
Scanner scan = new Scanner(System.in);
int x = scan.nextInt();
for(int i=1; i<=x; i++) {
for(int j=i; j<=x; j++) {
System.out.print("*");
}
System.out.println("");
}
}
}
public class SikuKiriTerbalik {
public static void main(String[] args) {
System.out.print("Masukkan Banyak Baris: ");
Scanner scan = new Scanner(System.in);
int x = scan.nextInt();
for(int i=1; i<=x; i++) {
for(int j=i; j<=x; j++) {
System.out.print("*");
}
System.out.println("");
}
}
}
Jika masih bingung bisa lihat video tutorial dibawah ini ya 😁😁
No comments:
Post a Comment