@@ -0,0 +1,1440 @@
+package algorithms.warmup;%0D%0A%0D%0Aimport java.util.Scanner;%0D%0A%0D%0A/*%0D%0A * Problem Statement: %0D%0A * Your teacher has given you the task to draw the structure of a staircase.%0D%0A * Being an expert programmer, you decided to make a program for the same. You%0D%0A * are given the height of the staircase. You need to print a staircase as shown%0D%0A * in the example.%0D%0A * %0D%0A * Input Format: %0D%0A * You are given an integer N depicting the height of the staircase.%0D%0A * %0D%0A * Constraints:%0D%0A * 1 %3C= N %3C= 100%0D%0A * %0D%0A * Output Format: %0D%0A * Draw a staircase of height N in the format given below.%0D%0A * %0D%0A * For example:%0D%0A * #%0D%0A * ##%0D%0A * ###%0D%0A * ####%0D%0A * #####%0D%0A * ######%0D%0A * %0D%0A * Sample Input:%0D%0A * 6%0D%0A * %0D%0A * Sample Output:%0D%0A * #%0D%0A * ##%0D%0A * ###%0D%0A * ####%0D%0A * #####%0D%0A * ######%0D%0A */%0D%0Apublic class Staircase %7B%0D%0A%0D%0A    public static void main(String%5B%5D args) %7B%0D%0A        Scanner sc = new Scanner(System.in);%0D%0A        %0D%0A        int height = sc.nextInt();%0D%0A        %0D%0A        for (int i = height - 1, j = 1; i %3E= 0; i--, j++) %7B%0D%0A            printSpaces(i);%0D%0A            printStairs(j);%0D%0A            System.out.println();%0D%0A        %7D%0D%0A        sc.close();%0D%0A    %7D%0D%0A    %0D%0A    private static void printSpaces(int numSpaces) %7B%0D%0A        for (int i = 0; i %3C numSpaces; i++) %7B%0D%0A            System.out.print(%22 %22);%0D%0A        %7D%0D%0A    %7D%0D%0A    %0D%0A    private static void printStairs(int numStairs) %7B%0D%0A        for (int i = 0; i %3C numStairs; i++) %7B%0D%0A            System.out.print(%22#%22);%0D%0A        %7D%0D%0A    %7D%0D%0A%7D

Add Staircase