$\begingroup$

I have got the following task:

(1) For each $n \in \mathbb{N}$, specify matrices $A, B \in \mathbb{R}^{n \times n}$ for which $A B \neq B A$ is true.

(2) Determine $$ M:=\left\{A \in \mathbb{R}^{2 \times 2}: A B=B A \quad \forall B \in \mathbb{R}^{2 \times 2}\right\} $$ thus the matrices $A \in \mathbb{R}^{2 \times 2}$, which commute with all matrices $B \in \mathbb{R}^{2 \times 2}$.

Could someone please help me with this or give me an approach? That would be very helpful. Thanks.