TITLE: Useful examples of pathological functions
QUESTION [25 upvotes]: What are some particularly well-known functions that exhibit pathological behavior at or near at least one value and are particularly useful as examples?
For instance, if $f'(a) = b$, then $f(a)$ exists, $f$ is continuous at $a$, $f$ is differentiable at $a$, but $f'$ need not be continuous at $a$.  A function for which this is true is $f(x) = x^2 \sin(1/x)$ at $x=0$.

REPLY [3 votes]: The constant function $0$ is an extremely pathological function: it has all kinds of properties that almost none of the functions $\mathbb R\to\mathbb R$ have: it is everywhere continuous, differentiable, analytic, polynomial, constant (not all of those are independent of course...), you name it. By contrast many of the answers given here involve properties that almost all functions have, or that almost all functions with the mentioned pathologies (e.g., being everywhere continuous for the Weierstrass function) have.
In fact being a definable function is a pathology that all answers share, but this is admittedly hard to avoid in an answer.