A curated collection of fun, interactive, and visually engaging Python projects.
An elegant Python script that uses the built-in turtle module to draw a beautifully layered pink heart on a black canvas, filled with multiple repetitions of the text "I Love You". It combines math (parametric equations for heart shapes) and creative coding.
Below is the mathematical representation used to construct the heart curve:
- (x = 16 \sin^3(\theta))
- (y = 13 \cos(\theta) - 5 \cos(2\theta) - 2 \cos(3\theta) - \cos(4\theta))
This project uses standard Python libraries. You only need:
- Python 3.x
- Tkinter (usually pre-installed with Python on Windows/macOS. For Linux, install using
sudo apt-get install python3-tk)
-
Clone the repository:
git clone <repository-url> cd fun-python-projects
-
Run the turtle program:
python index.py
A colorful geometry project demonstrating loops, list indexing, and basic angles in computer graphics. It renders a beautiful multi-colored spiral star shape that grows dynamically.
Run the spiral star program:
python spiral_star.pyA geometric design that demonstrates circular arcs, coordinate movements, and custom color fills. The Yin Yang symbol uses nested circles to show balance and symmetry.
Run the Yin Yang program:
python yin_yang.pyA vibrant geometric mandala crafted from overlapping, rotated petal shapes. Demonstrates nested loops, trigonometric symmetry, and color palettes in Python.
Run the flower mandala program:
python flower_mandala.pyA 3D-styled block letter 'P' drawn using precise coordinate paths, custom fills, and cutout shapes. Teaches beginner programmers how to construct custom typography with Turtle graphics.
Run the letter art program:
python letter_art.pyA glowing geometric spiral created using a 59-degree rotational offset and a multi-color neon palette. Excellent for learning color lists, line thickness scaling, and turtle rotation math.
Run the neon hexagon program:
python neon_hexagon.py- Language: Python 3
- Libraries:
turtle(Standard Library),math(Standard Library)