TITLE: Measure of the boundary
QUESTION [5 upvotes]: Let us been given a bounded domain $A\subset \mathbb{R}^n$. There is a function $u:A\to[0,1]$ such that 
$$
A' = \{x\in A:u(x) = 1\}
$$
is not empty and $u\in Lip(A)$ with rate $\alpha$. Is it right that $\mu(\partial A') = 0$ where $\mu$ is Lebesgue measure? If not, please help me to construct a counterexample, if yes - please, help me to prove it.

REPLY [5 votes]: For every $x$ in $\mathbb{R}^n$ and every closed set $B\subset\mathbb{R}^n$, let $$d(x,B)=\inf\{\|x-y\|;y\in B\}.$$ Then $d(x,B)=0$ if and only if $x$ belongs to $B$ and, for every $x$ and $y$ in $\mathbb{R}^n$, $$|d(x,B)-d(y,B)|\le\|x-y\|.$$
Choose $B\subset A$ and define the function $u$ on $A$ by $$u(x)=2^{-d(x,B)}.$$ Then $u$ is Lipschitz continuous and $A'=\{u=1\}=B$. Thus, the boundary of $A'$ may be the boundary of any closed set. In particular, it may have positive Lebesgue measure.