I know a monotone function of a closed and bounded interval can have at most countably many point of discontinuity. And hence a monotone function on $\mathbb R$ can have at most countably many point of discontinuity since $\mathbb R=[0,1]\cup[1,2]\cup[2,3]\cup...\cup[-2,-1]\cup[-3,-2]\cup...$
Now my question is
Does a monotone function on an arbitrary subset of $\mathbb R$ always have at most countable number of discontinuity?
Does the funtion $f:(\mathbb R-\mathbb Q)\to\mathbb R:x\mapsto x$ serve our purpose?
Suppose $f: D \rightarrow \mathbb{R}$ is a monotone function with cardinality $C$ discontinuities, where $D \subset \mathbb{R}$. Define the extended function $\tilde{f}$ by setting $\tilde{f}(x) = f(x)$ when $x \in D$, and for each $x \notin D$ $$\tilde{f}(x) = \inf_{y \in D, y > x} f(y).$$ Thus $\tilde{f}$ extends $f$ by interpolating horizontally across subsets of $\mathbb{R} \setminus D$. Then $\tilde{f}: \mathbb{R} \rightarrow \mathbb{R}$ is monotone and has cardinality $C'$ discontinuities, where $C' \geq C$. Since $C' \le \aleph_0$, then also $C \le \aleph_0$, so $f$ has at most countably many discontinuities.