Skip to content

this is a simple program for beginners to learn print triangles and shapes

License

Notifications You must be signed in to change notification settings

SaraAlhaddadi/triangles-and-shapes

Repository files navigation

Triangles and Shapes 📐 ✨

Welcome to Triangles and Shapes! 🎉 This beginner-friendly Python program is designed to help you learn and create various shapes and patterns. Whether you're new to programming or looking to expand your skills, this repository is a great starting point to explore the world of shapes and have fun with Python! 🚀

Features 🌟

  • Alphabetical Triangle 🔡: Print a triangle made of alphabetical characters.
  • Arrow Shape ⬆️: Create an arrow shape using numbers.
  • Custom Shape ✨: Design your own shape by inputting characters of your choice.
  • Inverse Triangle ⤵️: Generate an inverted triangle pattern.
  • Shape 1 🔢: Draw a unique pattern using alternating numbers.
  • Stars Diamond 💫: Print a diamond shape made of stars.
  • Two Triangles ➖: Create two triangles with different orientations.
  • Triangles 🏔️: Generate a pyramid-like pattern made of numbers.

How to Use ❓:

  1. Clone or download the repository to your local machine. 🖥️

  2. Open the project in your Python development environment. 🐍

  3. Navigate to the desired shape script. 📂

  4. Run the script and observe the output in the console. ▶️

  5. Modify the scripts and experiment with different inputs to create your own variations. ✏️

Examples 💡

Let's take a look at some examples of the shapes you can create:

alphbetic_triangle.py 🔡

     A
    AB
   ABC
  ABCD
 ABCDE

arrow.py ⬆️

   1 
  1 2 
 1 2 3 
   1 
   1

custom_shape.py ✨

example 1:

enter tow or more characters >>> ASE
 
ASEESA
AS  ES
A    E
A    A
AS  AS
ASEASE

example 2:

enter tow or more characters >>> OOoOO
 
OOoOOOOoOO
OOoO  OOoO
OOo    OOo
OO      OO
O        O
O        O
OO      OO
OOo    OOo
OOoO  OOoO
OOoOOOOoOO

example 3:

enter tow or more characters >>> -//**//-       
 
-//**//--//**//-
-//**//  -//**//
-//**/    -//**/
-//**      -//**
-//*        -//*
-//          -//
-/            -/
-              -
-              -
-/            -/
-//          -//
-//*        -//*
-//**      -//**
-//**/    -//**/
-//**//  -//**//
-//**//--//**//-

inverse_triangle.py ⤵️

12345    
 1234   
  123  
   12 
    1

shape1.py 🔢

1   1
 2 2 
 4 4 
5   5

Stars_Diamond.py 💫

   * 
  * * 
 * * * 
* * * * 
 * * * 
  * * 
   * 

tow_triangle.py 🔺🔺

#####
####
###
##
#
##
###
####
#####

triangles.py 🏔️

---------1
--------121
-------12421
------1248421
-----1248168421
----12481632168421
---124816326432168421
--12481632641286432168421

Feel free to explore and modify the scripts to create your own shapes and patterns. Don't be afraid to experiment and unleash your creativity! 🎨

Contributing 🤝

If you have ideas for new shapes or improvements to existing ones, feel free to contribute! Fork the repository, make your changes, and submit a pull request. Let's learn and grow together! 🌱

License 📃

This project is licensed under the MIT License. Feel free to use, modify, and distribute the code for personal and educational purposes.

About the Author 💻:

Hi there! I'm Sara Alhaddadi, the creator of Triangles and Shapes. I'm passionate about coding and love sharing knowledge with others. Connect with me on GitHub to discover more exciting projects! Get Started! 🚀

Ready to dive into the world of shapes? Get started with Triangles and Shapes by exploring the scripts and creating your own patterns. Happy coding and have fun! 🎉

About

this is a simple program for beginners to learn print triangles and shapes

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages