Answers for "staircase hackerrank solution python"

0

staircase hackerrank solution python

def staircase(num_stairs):
    for stairs in range(1, num_stairs + 1):
        print(' ' * (num_stairs - stairs) + '#' * stairs)
Posted by: Guest on May-06-2021
0

staircase hackerrank solution python

from __future__ import print_function

def staircase(num_stairs):
    n = num_stairs - 2
    for stairs in range(1, num_stairs):
        print(' ' * n, '#' * stairs)
        n -= 1
    print('#' * num_stairs)
Posted by: Guest on May-06-2021

Code answers related to "staircase hackerrank solution python"

Python Answers by Framework

Browse Popular Code Answers by Language