Let $X$ be a topological space and $A$ be a non-empty subset of $X$. Then one can conclude that if $X\setminus A$ is nowhere dense in $X$, $A$ is dense in $X$,
Is the above statement true in general? I know if $A$ is open then the result is true, but I am not sure otherwise.
No, that is not true in general.
Consider $X = \mathbb{R}$. Clearly $A = \mathbb{Q}$ is dense in $\mathbb{R}$, but $\mathbb{R} \setminus \mathbb{Q}$ is also known to be dense as well.