at my school there are 24 classes and ~50 teachers.

so that mean i need only 24 teachers in the first hours.

so more than 50% have got free the first morning hours.

if you want to increase that value, than you need to reduce the number of part time working teachers. so hire only full time working teachers.

an other variant might be adding team teaching activities always in the first hour or if you have got more courses than classes you can place all courses in the first hour. by that you will increase the number of teachers that are working in the wirst hour. but it also mean you will increase the number of hours of teachers that have gor free the last hours of a day and/or you will increase the number of teacher gaps.