I was given the following statement to show as an exercise, but I'm at a loss on how to proceed.
Let $\kappa$ be an uncountable regular cardinal, and $L$ be a countable language. Suppose $(M_\alpha : \alpha < \kappa)$ is an increasing and continuous (i.e. $M_\gamma = \bigcup_{\alpha < \gamma} M_\alpha$ for limit ordinals $\gamma$) sequence of $L$-structures, and let $M = \bigcup_{\alpha < \kappa} M_\alpha$. Show that $S = \{ \alpha \in \kappa : M_\alpha \prec M \}$ is a closed unbounded (club) set.
Here's what I have so far for the closure proof.
Take $A \subseteq S$ and let $\gamma = \lim A$. We want to show that $\gamma \in S$. Since $\kappa$ is regular, we know that $\gamma < \kappa$, so we just need to see that $M_\gamma \prec M$. To do so, we will check the Tarski-Vaught criterion. Take an arbitrary $L$-formula $\phi$ and suppose that there exists $a \in M$ such that $M \models \phi(a)$. Now we need to find $b \in M_\gamma$ such that $M_\gamma \models \phi(b)$. Note that $a \in M = \bigcup_{\alpha < \kappa} M_\alpha$ implies that $a \in M_\alpha$ for some $\alpha$. We now need to show that $\alpha \in A$ to satisfy the Tarski-Vaught criterion.
It's not clear to me how $\alpha$ can possibly be in $A$ in general though.
For unboundedness, I'm not sure at all how to begin.
Thanks in advance.
EDIT: Alex Kruckman pointed out a missing hypothesis in your problem. However, note that that hypothesis is not needed for what I've written below (the "closed" part of club)! Regardless of the sizes of the $M_\alpha$s, the set of indices of elementary substructures will always be closed (though it may be empty).
You want to show that $M_\gamma\prec M$. To do this, we'll use Tarski-Vaught, which states:
So suppose $\varphi$ were such a formula. The formula $\varphi$ uses finitely many parameters from $M_\gamma$ and $\gamma$ is a limit element of $S$, so we may find some $\beta<\gamma$, $\beta\in S$ such that each parameter in $\varphi$ is in $M_\beta$.
Now since $M_\beta\prec M$, there is some $b\in M_\beta$ such that $M\models\varphi(b)$. But $M_\beta\subseteq M_\gamma$, so $b\in M_\gamma$.