Both can be correct depending on how it's used.
1.What did he fail? (More natural)
He failed the exam.
Where did he fail? Which area did he fail?
He failed in the exam.
(But he did well in his classwork and attendance)
١٨ يوليو ٢٠٢٠
1
3
1
He failed the exam (without the preposition 'in').