Suppose $A$ and $B$ have the same eigenvalues $\lambda_1, \cdots, \lambda_n $ with the same independent eigenvectors $\mathbf{x_1, \cdots, x_n}$. Then $A = B$. Reason: Any vector $\mathbf{x}$ is a combination $\sum_{1 \le j \le n} c_j\mathbf{x_j}$. What are $A\mathbf{x}$ and $B\mathbf{x}$?
Solution (cp P4 of 6 of this PDF):

Similarly, $B\mathbf{x} = \sum\limits_{1 \le j \le n} c_j\lambda_j\mathbf{x_j} $. Then conclude by virtue of If $Ax = Bx$ for all $x \in C^{n}$, then $A = B$.
The question wrote $\mathbf{x} = \sum\limits_{1 \le j \le n} c_j\mathbf{x_j}$. What is $x$? Any vector in $\mathbb{C^n}$?
If so, how can every possible vector be written as a linear combination of the eigenvectors?What's the intuition behind the above result : Two matrices are the same when they have the same eigenvalues and eigenvectors?