Character-frequency distribution
ID: character-frequency-distribution
For a nonempty string, assign a character its occurrence count divided by the string length. Counts partition the character positions, proving normalization. Empty input has no total count to normalize and needs an explicit alternative contract or rejection. A Scala Char implementation counts UTF-16 code units unless a separate code-point representation is introduced.
New to topics? Read the docs here!