exercism-cpp / pascals-triangle /
@Wook Song Wook Song authored on 20 Oct 2022
..
.exercism Easy: Add solutions for three exercises 3 years ago
test Easy: Add solutions for three exercises 3 years ago
CMakeLists.txt Easy: Add solutions for three exercises 3 years ago
HELP.md Easy: Add solutions for three exercises 3 years ago
README.md Easy: Add solutions for three exercises 3 years ago
pascals_triangle.cpp Easy: Add solutions for three exercises 3 years ago
pascals_triangle.h Easy: Add solutions for three exercises 3 years ago
pascals_triangle_test.cpp Easy: Add solutions for three exercises 3 years ago
README.md

Pascal's Triangle

Welcome to Pascal's Triangle on Exercism's C++ Track. If you need help running the tests or submitting your code, check out HELP.md.

Instructions

Compute Pascal's triangle up to a given number of rows.

In Pascal's Triangle each number is computed by adding the numbers to the right and left of the current position in the previous row.

    1
   1 1
  1 2 1
 1 3 3 1
1 4 6 4 1
# ... etc

Source

Created by

  • @rrtheonlyone

Contributed to by

  • @elyashiv
  • @KevinWMatthews
  • @patricksjackson

Based on

Pascal's Triangle at Wolfram Math World - http://mathworld.wolfram.com/PascalsTriangle.html