\documentclass[a4paper,12pt]{article}
\newcommand\ds{\displaystyle}
\begin{document}

\parindent=0pt

QUESTION

Evaluate the product \textbf{AB} of the matrices

$$\textbf{A}=\left(\begin{array}{cc}2&-1\\-2&0\\1&1\end{array}\right),
\hspace{1cm}
\textbf{B}=\left(\begin{array}{ccc}1&-2&2\\2&0&1\end{array}\right).$$

\bigskip

ANSWER

\begin{eqnarray*}
\textbf{AB}&=&\left(\begin{array}{cc}2&-1\\-2&0\\1&1\end{array}\right)
\left(\begin{array}{ccc}1&-2&1\\2&0&1\end{array}\right)\\&=&
\left(\begin{array}{ccc}2(1)-1(2)&2(-2)-1(0)&2(1)-1(1)\\
-2(1)+0&-2(-2)+0&-2(1)+0\\1(1)+1(2)&1(-2)+0&1(1)+1(1)\end{array}\right)\\
&=&\left(\begin{array}{ccc}0&-4&1\\-2&4&-2\\3&-2&2\end{array}\right)
\end{eqnarray*}




\end{document}
