Last active
May 26, 2021 07:30
-
-
Save bharathmuddada/6b0705b6ef0afef04a08d73771134620 to your computer and use it in GitHub Desktop.
Inverted Triangle Pattern in Python
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| n = int(input("Enter your number \n")) | |
| for i in range(n): | |
| for j in range(n-i): | |
| print('*', end="") | |
| print() | |
| ''' | |
| Output: | |
| ***** | |
| **** | |
| *** | |
| ** | |
| * | |
| ''' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment