Skip to content

Commit

Permalink
Question1
Browse files Browse the repository at this point in the history
  • Loading branch information
Raushan-Kumar007 committed Jun 22, 2022
1 parent 67d5e18 commit a2debbf
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions pattern/pattern4.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
package pattern;

import java.util.Scanner;

public class pattern4 {
static void printP4(int n){
for(int i=1; i<=n; i++){
for(int j=1; j<=n; j++){
System.out.print(" ");
}
System.out.print("*");
}
System.out.println();
}
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int n= scan.nextInt();
printP4(n);
}
}

0 comments on commit a2debbf

Please sign in to comment.