Skip to content

Instantly share code, notes, and snippets.

@oper6210
Created July 10, 2018 13:33
import java.util.Scanner;
public class Main {
public static void main(String[] args){
Scanner sc=new Scanner(System.in);
int a = sc.nextInt();
String b="*";
int cnt= 0;
for(int i=0; i<a; i++) {
cnt++;
for(int j=0; j<cnt; j++) {
System.out.print(b);
}
System.out.println();
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment