Here is a code snippet to print a Christmas tree in Python:
main.py190 chars6 lines
To print a tree of height 5, you can call the function as follows:
main.py14 chars2 lines
This will output:
main.py48 chars7 lines
You can modify the function to print different shapes or add decorations to the tree. Happy Coding!
gistlibby LogSnag