Translation:Do you know why they are angry?
It's a somewhat subtle point, but we need the "吗" in this sentence because "为什么" isn't functioning as a question word - the question is whether or not the person being asked (你) knows why (知道为什么) the other group of people (他们) are angry. So a valid response to this question could simply be "我(不)知道" without actually explaining why the people in the other group are angry; but on the other hand the question "他们为什么生气" calls for an explicit explanation of "why they are angry" because in this case "为什么" now functions as a question word.
If we leave off the "吗" in the original sentence, then the sentence becomes the assertion "你知道他们为什么生气" meaning "you know why they are angry".
I'm curious as to why this is "Do you know why they are angry?" and not "Why do you think they are angry?"
Is there something semantic I'm missing here? The first line would be looking for a yes or no, but the second one would be looking for the reason. I don't know how to tell from the Chinese characters that that's what they're looking for.
That would be 你觉得/认为/以为(the last sounds like something someone from 'ancient' times would say)他们为什么（会）生气？or simply 他们为什么生气（了）？
Not sure I understand the question, but the main question here is 你知不知道？which is essentially a yes or no question.
It is not gramatically correct in Standard English. The question in the subordinate clause does not inverse the subject and the verb.
It seems to me that the particle 了 is called for here, since the people in question have become angry: 你知道他们为什么生气了吗？In 生气, the 生 is a verb, so by definition if one is angry then the 生 has happened and should past tense.
That doesn't follow proper English grammar. Switch the order of "are" and "they", and you'll get an answer that is accepted. It should be: Do you know why they are angry?
If you ask a question that begins with "why" (such as, "Why is the sky blue?") then yes, "Why are they angry" is the correct verb placement. But since the question is "Do you know [something]?" then the proper verb placement is "why they are angry".