3B. A tower made of cards requires 2 cards for one level, 7 cards for two levels, and 15 cards for a tower of three levels (see diagram). How many cards are needed for a tower of $n$ levels?
Solution. For the first row (counted from the top), one card tilted to the right, one tilted to the left, and no horizontal cards are needed; for the second row, two cards tilted to the right, two to the left, and one horizontal card are needed; for the third row, three cards tilted to the right, three to the left, and two horizontal cards are needed, and so on until the $n$-th row, for which $n$ cards tilted to the right, $n$ to the left, and $n-1$ horizontal cards are needed. Therefore, the total number of cards required is:

$$
\begin{aligned}
(1+1+0)+(2+2+1)+\ldots+[n+n+(n-1)]= & 2(1+2+3+\ldots+n)+(1+2+3+\ldots+n-1) \\
& =\frac{2 n(n+1)}{2}+\frac{(n-1) n}{2}=\frac{n(3 n+1)}{2}
\end{aligned}
$$