Answer
a) John
b)Carlos
Work Step by Step
a)
Immediately we can see that either Carlos or Diana are lying.
If Carlos is telling the truth, so is John.
So, Carlos cannot be telling the truth (because then 2 people would be telling the truth).
Therefore, Diana is telling the truth. But then, John cannot be telling the truth. Therefore, John has to be the one who did it.
b)
Again, either Carlos or Diana are lying.
Also, either Carlos or Alice are lying.
Therefore, Carlos is the only possible guilty one. That is also consistent with John's statement.