Skip to content

aprilmintacpineda/triangle-of-pascal

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 

Repository files navigation

Pascal's triangle

What

Pascal's triangle, named after Blaise Pascal is a triangle of hexagons (I'll call cell). Where the number of cells each row is n + 1 where n is initially 1. So row 0 (which is the tip if the triangle) would have 1 cell in it, row 1 would have 2 cells in it, row 2 would have 3 cells in it, and so on.

These cells would have value. The value would be the sum of the value of the cell above it to the left and the value of the cell above it to the right. If no cell is present on both sides (which would be the case for the cell on the tip of the triangle), then the value would be 1, if no cell is present on one side (which would be the case for the cells on the sides of the triangle), the value of that side is presumed to be 0.

example

taken from WikiPedia.

Created with <3 by April Mintac Pineda