What is the mathematical distinction between closed and open sets? If you wanted me to spell out the difference between closed and open sets, the best I could do is to draw you a circle one with dotted circumference the other with continuous circumference. Or I would give you an example with a set of numbers $(1, 2)$ vs $[1,2]$ and tell you which bracket signifies open or closed.
But in many theorems the author is dead set about using either closed or open sets. What is the strict mathematical difference that distinguish between the two sets and signifies the importance for such distinction?
Can someone demonstrate with an example where using closed set for a theorem associated with open set would cause some sort of a problem?

Let's talk about real numbers here, rather than general metric or topological spaces. This way we don't need notions of Cauchy sequences or open balls, and can talk in more familiar terms.
We define that a set $X \subset \mathbb{R}$ is open if for every $x \in X$ there exists some interval $(x-\epsilon,x+\epsilon)$ with $\epsilon > 0$ such that this interval is also fully contained in $X$.
An example is the inverval $(0,1) =\{x \in \mathbb{R} : 0 < x < 1\}$. Note that this is an infinite set, because there are infinitely many points in it. If you choose a number $a \in (0,1)$ and let $\epsilon = \min\{a-0, 1-a\}$ then we can guarantee that $(a-\epsilon,a+\epsilon) \subset X$. The set $X$ is open.
A set $X$ is defined to be closed if and only if its complement $\mathbb{R}- X$ is open. For example, $[0,1]$ is closed because $\mathbb{R}-[0,1]= (-\infty,0)\cup(1,\infty)$ is open.
It gets interesting when you realise that sets can be both open and closed, or neither. This is a case where strict adherence to the definition is important. The empty set $\emptyset$ is both open and closed and so is $\mathbb{R}$. Why? The set $[1,2)$ is neither open nor closed. Why?
