Question: Show that for any alphabet $E$ of size $[E]=m$ $(m>0)$, there exists a prefix code $f: E \to \{0,1\}*$ with codeword lengths $l = 1,2,\dots,m$.
Just started this topic on Coding and have just learnt about Kraft's Inequality not sure how I would go about showing there exists a prefix code for this alphabet is this something I need to find as a follow up from Kraft's Inequality. Any help or guidance would be greatly appreciated!
Kraft’s inequality can be used here. It says that if your input alphabet $E$ has size $n$, your codeword alphabet has size $r$, there is a prefix code with codeword lengths $\ell_1,\ldots,\ell_n$ if and only if
$$\sum_{k=1}^n\left(\frac1r\right)^{\ell_k}\le 1\;.\tag{1}$$
Once you’ve answered that, substitute the appropriate values into the summation in $(1)$ and evaluate it to see whether it is indeed less than or equal to $1$.