Let
x=Sum of ages of teachers
Mean=x/25
40=x/25
x=40×25
=1000
A new teacher appointed in place of a teacher whose age is 60
.So, Sum of ages of remaining 24 teachers
=x−60
=1000-60
=940
.The sum of ages of all 25 teachers including new teacher
=39×25
=975
....
∵the mean=39
Now,
975−940 = Age of new teacher
Therefore, age of new teacher is
35years.