Expected codeword length
= Expected codeword length
{title2=$L(c)$}
For a source symbol $X$ and a code $c$, the expected codeword length is
$$
L(c)=\mathbb E[|c(X)|]=\sum_xP(X=x)|c(x)|.
$$
= Expected codeword length
{title2=$L(c)$}
For a source symbol $X$ and a code $c$, the expected codeword length is
$$
L(c)=\mathbb E[|c(X)|]=\sum_xP(X=x)|c(x)|.
$$