Deviopath › JavaScript

Pascal's Triangle Row

Medium · Arrays

Write a function pascalRow that returns row n of Pascal's triangle (row 0 is [1]).

Each row starts and ends with 1, and every other number is the sum of the two numbers just above it in the previous row.

Next: Load User Names