Getting to school is very difficult for some people, especially if they come from a poor family. In high school, just getting there was such a hassle. I took three different busses. I remember getting up a 5 a.m. to get to there. And my student advisor(the principal) told me I needed to work on my attitude.
To take it further, never understood the reason to be at pretty much any job before 10 a.m.
Construction is notorious for early hours. Pretty much nothing gets done before that first coffee break.
Worked in flooring last year. Hours were 8 to 4. Coffee stop was on the way in. Generally started right away, but that's more of a show-up-to-customer-and-get-to-work deal. Couldn't start before 8 because noise
A fixed and mandatory early start time serves as a proxy for general discipline and a means to conclusively demonstrate one's willingness to follow instructions and do things in the institutionally mandated way despite personal dislike of them.
More realistically, I've worked flex jobs and no matter how much waking up at 4am sucks, going home from work at 2pm rocks so much more that it balances out.