Show that if $A$ and $B$ are sets, then $A \subseteq B$ if and only if $A \cap B = A$. I'm working through a real analysis textbook, and it starts out with set theory. The first exercise is

Show that if $A$ and $B$ are sets, then $A \subseteq B$ if and only if $A \cap B = A$.

I think I proved it correctly but I'm not sure. Here's what I did. I proved that if $A \subseteq B$, then $A \cap B = A$ the same way as this answer did (https://math.stackexchange.com/a/446114/93114), but I want to make sure I proved the converse correctly because it seems really easy (yes it's the first problem in the book, but still) and math usually isn't this easy for me, even the basic stuff!
Proof of "If $A \cap B = A$, then $A \subseteq B$."
If $x \in A \cap B$, then $x \in A$ and $x \in B$, but this applies to all $x \in A$ because $A \cap B = A$. So, for any $x \in A$, we know that $x \in B$, so $A \subseteq B$.
Am I on the right track?

Suppose $A\cap B=A$. To prove $A\subseteq B$, suppose $x\in A$. Since $A\cap B=A$, $x\in A\cap B$ and thus $x\in B$. Since $x$ was an arbitrary element of $A$, this holds for all $x$ and thus $A\subseteq B$.
The above proves $A\cap B=A\implies A\subseteq B$. You will then need to prove the reverse implication to establish $A\cap B=A\iff A\subseteq B$.
