Look how the pyramid is constructed.
The pyramid is constructed inside an equilateral triangle of size n sticks. It is filled with small equilateral triangles of size 1.
If `a_n ` is the number of small triangles in the big triangle of side n.
`b_n` is the number of sticks needed to fill the big triangle of side n.
It build the next step, we just need to add n+1 small upward traingles of side 1
/_\ /_\ ... /_\
Which means we add 3(n+1) sticks.
How many small triangles were added?
(n+1) upward and n downward. i.e 2n+1 in total.
Let's try to find a expression of `b_n` as a function of n
Let's find `a_n`
Therefore, at the level n there are `3n(n+1)/2` sticks and `n^2 ` triangles.