Build a Pascal's Triangle by printing each line.
Implement pascal_triangle(num_rows) to return the rows in order, where each row is a list of integers. The caller can print each returned row as one line. For zero rows, return an empty list.
Input: A non-negative integer num_rows.
Output: A list containing num_rows rows of Pascal's Triangle.
Examples:
num_rows = 5 returns [[1], [1, 1], [1, 2, 1], [1, 3, 3, 1], [1, 4, 6, 4, 1]].num_rows = 0 returns [].Constraints: 0 <= num_rows <= 30.
def pascal_triangle(num_rows):