the equivalent definition of the interval in $\mathbb{R}$ Let $X$ be a subset of the real line $\mathbb{R}$. Then the following statements are equivalent. 
(b) Whenever $x,y \in X$ and $x < y$, the interval $[x, y]$ is also contained in $X$. 
(c) $X$ is an interval (in the sense of Definition 9.1.1).
Definition 9.1.1. Let $a, b \in \mathbb{R}^*$ be extended real numbers. We define the closed interval $[a, b]$ by $[a, b] : = \{x \in \mathbb{R}^* : a \le x \le b\}$. The half-open intervals and the open intervals are defined in a similar fashion. 
(c) $\implies$ (b) is easy. 
If $X$ is closed (which I don't know), $\inf X, \sup X \in X$. This implies that $[\inf X, \sup X] = X$. Letting $a = \inf X$ and $b= \sup X$, we have the desired result. But, without knowing that $X$ is closed, how can we show that (b) $\implies$ (c)? 

Hint: To show that $X$ is one of the intervals $[a,b], (a,b),[a,b),(a,b]$ (where $a =\inf X, b=\sup X$) you only have to show that $x \in X$ whenever $a <x<b$. So it makes no difference as to whether $X$ is closed or not. 
Use definitions of infimum and supremum to show that $c<x<d$ for some $c,d \in X$. Then use b) to conclude that $x \in X$. 
