The average mark of the students of a class in a particular exam is 80. If 5 students whose average mark in that exam is 40 are excluded, the average mark of the remaining will be 90. Find the number of students who wrote the exam.

The average mark of the students of a class in a particular exam is 80. If 5 students whose average mark in that exam is 40 are excluded, the average mark of the remaining will be 90. Find the number of students who wrote the exam.

A. 20
B. 15
C. 25
D. 35
Let the number of students who wrote the exam be x.
Total marks of students = 80 x.
Total marks of (x – 5) students = 90(x – 5)
80x – (5 * 40) = 90(x – 5)
250 = 10x => x = 25