diff --git a/python/5-triangles-part-1/README.md b/python/5-triangles-part-1/README.md index e276820..54a9a04 100644 --- a/python/5-triangles-part-1/README.md +++ b/python/5-triangles-part-1/README.md @@ -1,19 +1,17 @@ -####Print a Triangle - -##Using nested for loops, print a triangle like so: - -`*` -`**` -`***` -`****` -`*****` -`******` -`*******` -`********` -`*********` -`**********` - -This triangle is 10 high, but I want the ability to make it as high as I want by setting one variable. - -You can print this to the console or to the printout div. +Print a Triangle +================ +Using nested for loops, print a triangle like so: +``` +>>> triangle(10) +* +** +*** +**** +***** +****** +******* +******** +********* +********** +``` diff --git a/python/5-triangles-part-1/triangle.py b/python/5-triangles-part-1/triangle.py new file mode 100644 index 0000000..43c16ce --- /dev/null +++ b/python/5-triangles-part-1/triangle.py @@ -0,0 +1 @@ +def triangle(num):