Skip to content

TheQueryCrew/P6-PascalsTriangle

Repository files navigation

Pascals Triangle

Write a Program to print the pascals triangle

Pascals Triangle:

Given numRows, generate the first numRows of Pascal's triangle.

Input:

Enter number of rows for generating Pascal's triangle : 5

Output:

1

1 1

1 2 1

1 3 3 1

1 4 6 4 1