Step 1: Find points where \(|x|\) is not differentiable.
For
\[
f(x)=|x|,\quad -\infty\lt x\lt 2,
\]
the function is not differentiable at
\[
x=0
\]
At \(x=0\),
\[
f(x)=|x|
\]
is continuous but left and right derivatives are unequal.
Hence,
\[
a=0
\]
Step 2: Analyze the second part of the function.
For
\[
f(x)=|2x-4|,\quad 2\leq x\leq 20,
\]
the expression inside modulus becomes zero at
\[
2x-4=0
\]
\[
x=2
\]
Thus, \(f(x)\) is not differentiable at
\[
x=2
\]
Hence,
\[
b=2
\]
Step 3: Check continuity at \(x=2\).
Left-hand limit:
\[
\lim_{x\to 2^-}|x|=2
\]
Right-hand limit:
\[
\lim_{x\to 2^+}|2x-4|=0
\]
Since
\[
2\neq 0,
\]
the function is discontinuous at
\[
x=2
\]
Thus, \(x=2\) is a point where the function is not differentiable.
Step 4: Find \(a+b\).
We have
\[
a=0,\quad b=2
\]
Therefore,
\[
a+b=2
\]
Step 5: Final conclusion.
Hence,
\[
\boxed{2}
\]