Steric program with time in python

 import time

start = time.time()
= int(input("Enter the numbers of the rows: "))
bol =input("Start from start Enter: 0 Start from end enter: 1: ")

= 0
while i <= n:
    if bol == str("0"):
        print(i*"*")
    elif bol == str("1"):
        print((n-i)*"*")
    i+=1


print(time.time() - start)

Comments