We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Prepare
- Algorithms
- Warmup
- Staircase
- Discussions
Staircase
Staircase
Sort by
recency
|
5005 Discussions
|
Please Login in order to post a comment
Python Solution!
Can you help me to integrate this algorithm problem with my Quran page? I want to use it on my wordpress website
Java Solution :
public static void staircase(int n) { // Write your code here for(int i = 1 ; i <= n ; i++){ int spaces = n - i; for(int j = 0 ; j < spaces ; j++){ System.out.print(" "); } for(int k = 0 ; k < i ; k++){ System.out.print("#"); } System.out.println();
} }
Javascript solution
My Typescript Solution