(NOTE: This is not a homework question at at all. Rather, this was something that I thought that I understood (at least on the surface), but now appear to have no clue about, and am not currently finding any resources helpful. I know that we typically like to see what people have tried, but I am honestly discombobulated enough at this moment that I am truly unsure about where to even begin. If this turns out to be a duplicate that I haven't found, I would also be perfectly happy. I just want to understand.)
Anyway, on to the question itself:
So, if $\lambda xy.x$ represents true, and $\lambda xy.y$ represents false, then I have been told that $(\lambda b.b \ \ \lambda xy.y \ \ \lambda xy.x)$ is a
not function, because the expression
$(\lambda b.b \ \ \lambda xy.y \ \ \lambda xy.x) \ \lambda xy.x$ results in $\lambda xy.y$,
and the expression
$(\lambda b.b \ \ \lambda xy.y \ \ \lambda xy.x) \ \lambda xy.x$ results in $\lambda xy.x$.
Where I am stuck is that I don't see how to apply $\beta$-reductions here. There are three expressions inside the parenthesis. How is one of them chosen by applying the outer expression?