Python Program to Print Christmas Tree Star Pattern

Python Program to Print Christmas Tree Star Pattern

Write a Python program to print Christmas tree star pattern using for loop. width = int(input(“Enter Chirstmas Tree Width = “)) height = int(input(“Enter Chirstmas Tree Height = “)) space = width * height n = 1 print(“====The Chirstmas Tree Star Pattern====”) alphabet = 65 for x in range(1, height + 1): for i in … Read more

Python Program to Print Right Pascals Star Triangle

Python Program to Print Right Pascals Star Triangle

Write a Python program to print right pascals star triangle using for loop.  rows = int(input(“Enter Right Pascals Star Triangle Pattern Rows = “)) print(“====Right Pascals Star Triangle Pattern====”) for i in range(0, rows): for j in range(0, i + 1): print(‘*’, end = ‘ ‘) print() for i in range(rows – 1, -1, -1): … Read more

Python Program to Print Left Pascals Star Triangle

Python Program to Print Left Pascals Star Triangle

Write a Python program to print left pascals star triangle using for loop.  rows = int(input(“Enter Left Pascals Star Triangle Pattern Rows = “)) print(“====Left Pascals Star Triangle Pattern====”) for i in range(1, rows + 1): for l in range(i, rows): print(end = ‘ ‘) for m in range(1, i + 1): print(‘*’, end = … Read more

Python program to Print Sandglass Star Pattern

Python program to Print Sandglass Star Pattern

Write a Python program to print sandglass star pattern using for loop.  rows = int(input(“Enter Sandglass Star Pattern Rows = “)) print(“====Sandglass Star Pattern====”) for i in range(0, rows): for j in range(0, i): print(end = ‘ ‘) for k in range(i, rows): print(‘*’, end = ‘ ‘) print() for i in range(rows – 1, … Read more