Let $(X, \prec)$ and $(Y, <)$ be two well-ordered sets. Now, I want to understand the proof that $X$ is isomorphic to an initial segment of $Y$ or $Y$ is isomorphic with an initial segment of $X$.
Now, they define $\mathcal{F}$ to be the set of all mappings with as domain an initial segment of $X$ and $Y$ as codomain and $F: \mathcal{F} \to Y \cup \{Y\}$ as $F(f) = \text{min}(Y \setminus \text{ran} f)$ if $f$ is not surjective and equal to $Y$ if $f$ is surjective. Now, they want to apply the recursion principle to $F$ to get a mapping from $X$ to $Y \cup \{Y\}$ that satisfies $f(x) = F(f|_{\hat{x}})$ for all $x$. Now I wonder how this is possible with the Recursion principle because the codomain is different. (Arturo solved this (very easy...) question in the comments).
Further they begin $x \prec y$ in $X$ and $f(y) \neq Y$ then $f(x) \lt f(y)$, so I assume the above but then I see that (strict) $Y \setminus \text{ran} f|_{\hat{y}} \subset Y \setminus \text{ran} f|_{\hat{x}}$ but why would could the minimum not be equal?
Thanks.