This phenomenon is called rendaku, or "sequential voicing".
Many phonemes in Japanese occur in voiced/unvoiced pairs. In kana writing, these are distinguished with a dakuten "voice mark" over the voiced version: for instance, か /ka/, が /ga/.
(Side note: in a few cases this reflects historical rather than current pronunciation: /h/ voices to /b/ because it was originally /ɸ/, and /β/ isn't distinguished from /b/.)
Rendaku means that the first sound in the second part of a compound becomes voiced...most of the time. In reality, it's not quite this simple. There are a few additional rules:
- Branching constraints! This is what the NACLO problem is about.
- If the sound is already voiced, nothing happens to it
- Lyman's Law: rendaku doesn't happen if the second word contains any voiced obstruents
- Rendaku also doesn't happen in "A and B" compounds: so yama "mountain" + kawa "river" could become yamakawa "mountain and river" or yamagawa "river which is on a mountain"
So as you can see, rendaku isn't completely free from ambiguity. Already-voiced sounds such as /n/, /r/, /j/ aren't affected by it at all, which is what the footnote in the problem is pointing out. But there are also specific words which completely ignore rendaku, or which cause it to happen inconsistently. A few roots become voiced when attached to nouns, but not to verbs. It doesn't help that this voicing isn't indicated at all in kanji writing.
In these cases, the ambiguity has to be resolved the same way as in English: context, world-knowledge, and familiarity with the language.