How does Kaspa decide which coinbase output pays a merged block's reward?
Kaspa uses a block's position in a list called MergesetBlues to determine which coinbase transaction output pays that block's mining reward. When a block B is included in another block C's MergesetBlues — the ordered set of "blue" blocks that C merges — the protocol finds B's index (position number) in that list. The coinbase transaction of block C then has a corresponding output at that same index position, and that output is the one that pays the reward to the miner of B. This matters for beginners because it shows how Kaspa's blockDAG structure lets multiple miners get rewarded from a single block's coinbase transaction, rather than only the miner of the chain tip collecting a reward.