Skip to content

Instantly share code, notes, and snippets.

@Nempickaxe
Created November 12, 2023 15:03
Show Gist options
  • Save Nempickaxe/e7f71a8be9f43721476bcfc25cef6781 to your computer and use it in GitHub Desktop.
Save Nempickaxe/e7f71a8be9f43721476bcfc25cef6781 to your computer and use it in GitHub Desktop.
def print_shri_shri(rows):
for i in range(rows):
for j in range(rows - i - 1):
print(" ", end=" ")
for j in range(i + 1):
print("श्री ", end="")
print()
# Adjust the value of 'rows' based on how many rows of the Pascal triangle you want
rows = 5
print_shri_shri(rows)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment