Assume that the only dense subset is $X$ itself. What can you say something about the topology, that is, the family of open sets? Let $(X, d)$ be a metric space. Assume that the only dense subset is $X$ itself. What can you say something about the topology, that is, the family of open sets?
My Try: Since the only dense subset of $X$ is $X$ itself, so every subset of $X$ is a closed set.
 A: What does it mean for a subset $A$ of $X$ to be dense?  It means for each $x \in X$ and every open $U \subseteq X$ with $x \in U$, $U \cap A \neq \emptyset$.
So if $X$ is the only dense subset of itself, that means for each $x \in X$, $X - \{ x \}$ is not dense in $X$.  That means, in particular, that there is some $y \in X$ and some open $U \subseteq X$ such that $y \in U$ and $U \cap (X - \{ x \}) = \emptyset$.  But if this intersection is empty, then it must be that $y = x$ (why?).  It also must be that $U = \{ x \}$ (why?), and so $\{x \}$ is open.  But then that means that singletons are open.
But if $\{ x \}$ is open for each $x$, then it is easy to see that the topology on $X$ is actually the discrete topology (why?), i.e., the set of all subsets of $X$, which is the finest topology possible on $X$.
A: One thought: Every point is isolated. For if $x$ is a limit point of $X$, then the closure of $X-x$ is $X$. We assume this cannot happen, so $x$ must be isolated; hence the singleton of the arbitrary point $x$ is open. 
A: The original comment by user46944 is very much on point: the gap between ‘$X$ is the only dense subset of $X$’ to ‘every subset of $X$ is closed’ is far too large to be leaped in a single bound. There actually is a way to arrive at that result without using the approach of user46944 and Cass, but it takes a bit more work, and I definitely recommend their approach. In case you’re interested in trying it, I’ll sketch the main steps.
Suppose that $A\subseteq X$ is not closed. Let $D=A\cup(X\setminus\operatorname{cl}A)$.


*

*Prove that $D\ne X$.  

*Prove that $\operatorname{cl}D=X$ and hence that $D$ is dense in $X$.

