You are viewing a single comment's thread. Return to all comments →
How about this mate
public class Solution { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); for(int i=1;i<=n;i++) { for(int k=n;k>i;k--) { System.out.printf(" "); } for(int j=1;j<=i;j++) { System.out.printf("#"); } System.out.println(); } } }
Seems like cookies are disabled on this browser, please enable them to open this website
Staircase
You are viewing a single comment's thread. Return to all comments →
How about this mate