C++ Program to Print Pascal Triangle

Write a C++ Program to Print Pascal Triangle with an example. In this Pascal triangle example, long factorialNum(int number) finds the factorial of a number. Within the nested for loop, we used this method to get our pattern. #include<iostream> using namespace std; long factorialNum(int number) { long factorial = 1; for (int i = 1; … Read more