Skip to content

Latest commit

 

History

History

README.md

Stars Pattern

Written in Python

Written in C

Written in Shell

Can be use as a demo and/or learning purposes only.

Also for personal use. 😁

n = 5 by default

Increasing Triangle Pattern

Figure:

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

Decreasing Triangle Pattern

Figure:

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

Right Sided Increasing Triangle Pattern

Figure:

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

Right Sided Decreasing Triangle Pattern

Figure:

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

Hill Pattern

Figure:

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

Upside Down Hill Pattern

Figure:

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

Diamond Pattern

Figure:

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

Double Hill Pattern

Figure:

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

Butterfly Pattern

Figure:

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

Sand Glass Pattern

Figure:

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

Left Pascal's Triangle Pattern

Figure:

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

Right Pascal's Triangle Pattern

Figure:

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

With Python in Console, you can try with different size like python3 pattern.py 7


**Enjoy**

Written by Jovan De Guia

Socials

License under MIT License