Last active
June 14, 2019 22:43
-
-
Save joelibaceta/704abf87e1d5d1d59cc6cff72c385129 to your computer and use it in GitHub Desktop.
A monster code for draw a tree
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
c =0 | |
""" .""" | |
b = 34 | |
""" ###""" | |
while b > 0 \ | |
and c < 33 : | |
""" ############""" | |
print( '\33[1;32;48m' + \ | |
' '*b+'*'+'*'*c+'\33[0m') | |
""" #########################""" | |
b -=1 | |
c +=2 | |
""" """ | |
""" """ | |
for r in range(3): | |
print( ' ' * 33 + '||' ) | |
print( ' '*31 + '\====/\n') |
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
python tree.py | |
* | |
*** | |
***** | |
******* | |
********* | |
*********** | |
************* | |
*************** | |
***************** | |
******************* | |
********************* | |
*********************** | |
************************* | |
*************************** | |
***************************** | |
******************************* | |
********************************* | |
|| | |
|| | |
|| | |
\====/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment