# Convergence in measure of characteristic functions

I was having trouble starting this problem. I would appreciate some help. Thanks in advance.

Let $E_1, E_2, \ldots$ be measurable sets. Suppose that the functions $f_j = 1_{E_j}$ converge in measure to a limit function $f$. Show that $f$ is $a.e.$ equal to $1_E$ for some measurable set $E$.

-

Since $\{f_j\}$ converges in measure to $f$, there is a subsequence of $\{f_j\}$ that converges pointwise a.e. to $f$. But each $f_j$ is measurable and only takes two values, $0$ or $1$. Can you finish the proof?
Since $f_n \overset{\mu}{\longrightarrow} f$ we may choose a subsequence $g_n$ such that $g_n \to f$ a.e. Since the $g_n\in \{0,1\}$ for all $n$ in order that $g_n(x) \to f(x)$ for some $x$ we must have $g_n(x)$ becomes eventually constant. It follows that $f(x) \in \{0,1\}$ for a.e. $x$. Letting $S$ denote the set on which $g_n \to f$, to finish the claim it suffices to show $\{f = 1\} \cap S$ and $\{ f = 0\} \cap S$ are measurable. We have $\{f = 1\} \cap S = \cup_n \cap_{m \geq n} \{g_m = 1\}$ and similarly $\{f = 0\} \cap S=\cup_n \cap_{m \geq n} \{g_m = 0\}$ which finishes the proof.
Hint: Let $X_0=\{x\in \mathbb{R}:f(x)=0\}$ and $X_1=\{x\in \mathbb{R}:f(x)=1\}$, and let $X=X_0\cup X_1$--note that $X_1$ is measurable since $f$ is measurable. It suffices to show that $m(\mathbb{R}-X)=0$. To see this, suppose not, then there exists some $Y\subseteq\mathbb{R}$ such $f(y)\ne 0,1$ for all $y\in Y$. Try to show that this contradicts that $1_{E_j}\to f$ in measure.