\[a_{7} = 6;\ \ a_{17} = 26:\]
\[\left\{ \begin{matrix} a_{1} + 6d = 6\ \ \ \ \ \\ a_{1} + 16d = 26 \\ \end{matrix} \right.\ \text{\ \ \ }( - )\text{\ \ \ \ }\]
\[\left\{ \begin{matrix} - 10d = - 20\ \ \ \\ a_{1} = 26 - 16d \\ \end{matrix} \right.\ \text{\ \ \ \ \ }\]
\[\left\{ \begin{matrix} d = 2\ \ \ \ \ \\ a_{1} = - 6 \\ \end{matrix} \right.\ \]
\[S_{40} = \frac{2a_{1} + 39d}{2} \cdot 40 =\]
\[= \left( 2a_{1} + 39d \right) \cdot 20 =\]
\[= ( - 12 + 78) \cdot 20 = 1320.\]
\[Ответ:1320.\]