Determine whether the following statement is true or fase. If true, provide a proof; if false, provide a counterexample.

If S is a bounded set of real numbers, and S contains sup(S) and inf(S), then S is a closed interval.

To determine whether the statement is true or false, we need to prove or provide a counterexample.

Let's break down the statement into two parts:

1. If S is a bounded set of real numbers and S contains sup(S) and inf(S).
2. Then S is a closed interval.

To prove the statement, we need to show that both conditions hold.

1. If S is a bounded set of real numbers and S contains sup(S) and inf(S).
- A set S is bounded if there exist real numbers a and b such that a ≤ x ≤ b for all x in S.
- sup(S), the supremum of S, is the least upper bound of S, meaning it is the smallest real number that is greater than or equal to all elements of S.
- inf(S), the infimum of S, is the greatest lower bound of S, meaning it is the largest real number that is less than or equal to all elements of S.

2. Then S is a closed interval.
- A closed interval is a set of real numbers that contains its endpoints.
- A closed interval can be expressed as [a, b], where a and b are real numbers, and a ≤ b.

To prove the statement, we need to show that if S satisfies the conditions in 1, it must also satisfy the conditions in 2.

Proof:
Let S be a bounded set of real numbers that contains sup(S) and inf(S). We need to show that S is a closed interval [a, b], where a ≤ b.

1. Since S is bounded, there exist real numbers a and b such that a ≤ x ≤ b for all x in S.
2. Let's consider the supremum sup(S).
- By definition, sup(S) is the smallest real number that is greater than or equal to all elements of S.
- If there exists an element s in S such that s > sup(S), then sup(S) is not the supremum of S.
- Therefore, it must be the case that s ≤ sup(S) for all s in S.
- This implies a ≤ sup(S) ≤ b, as sup(S) is an element of S.
3. Similarly, let's consider the infimum inf(S).
- By definition, inf(S) is the largest real number that is less than or equal to all elements of S.
- If there exists an element s in S such that s < inf(S), then inf(S) is not the infimum of S.
- Therefore, it must be the case that s ≥ inf(S) for all s in S.
- This implies a ≤ inf(S) ≤ b, as inf(S) is an element of S.
4. From steps 2 and 3, we have a ≤ inf(S) ≤ sup(S) ≤ b.
5. Therefore, S is a closed interval [a, b], where a ≤ b.

By proving the conditions in 1 and 2, we have shown that if S is a bounded set of real numbers, and S contains sup(S) and inf(S), then S is a closed interval. Hence, the statement is true.

Note: While the proof shows that if the conditions hold, then S is a closed interval, it does not prove that every closed interval satisfies the conditions.