# How to prove $\sup(A) \leq \inf(B)$?

I have the following problem:

Let $$A, B \subseteq\mathbb{R}, A \neq \emptyset$$ and $$B \neq\emptyset$$ such that $$(\forall a \in A \wedge b \in B): a \leq b$$ Prove that $$\sup(A) \leq \inf(B)$$.

My attempt:

We know by definition that $$A$$ is bounded from below and $$B$$ is bounded from above, therefore by Completeness Axiom, we know there exist $$\sup(A)$$, and by theorem there exists $$\inf(B)$$.

Let $$a \in A$$ and $$b \in B$$, then $$a \leq \sup(A)$$ and $$\inf(B) \leq b$$. Hence, $$a + \inf(B) \leq \sup(A) + b$$

However, I don't have idea how to get $$\sup(A) \leq \inf(B)$$.

Hope you can help me :)

$$\sup A$$ is the least upper bound of $$A$$, that is, it is the least number which is greater than or equal to all elements of $$A$$ [1]. So by definition, $$\sup A\leq b$$ for all $$b\in B$$. Now, $$\inf B$$ is the greatest lower bound of $$B$$. And since $$\sup A\leq b,\, \forall b\in B$$, we have $$\sup A\leq \inf B$$.
Assume $$y= \inf (B) \lt \sup(A) = x$$. By the definition of $$\inf, \forall \epsilon \gt 0 \exists b \in B~(y \leq b \lt y+ \epsilon)$$. By the definition of $$\sup, \forall \epsilon \gt 0 \exists a \in A~(x - \epsilon \lt a \leq x).$$ Choose $$\epsilon = \frac{x-y}{3}.$$ Then $$b \lt y+ \epsilon \lt x - \epsilon \lt a$$, so $$\exists a \in A, b \in B \text{ with } b \lt a$$ contradicting our hypothesis.