I agree. I started comp after leaving primary as a straight A* pupil. Aged 16, I left the comp without a single qualification. That was because it was a crap comp, and I was bullied mercilessly for five years, incompetent/useless teachers did nothing to stop it, just played the "victim blaming" card of telling me to toughen up! Really helpful! Not just name calling, but physical abuse (fag burns, kicks, punches, etc), and theft/damage to property such as school books, coat, school bag, etc. Teachers couldn't give a shit. I started hiding at breaks and lunch times to avoid the bullies and then started truanting to avoid the lessons where I was forced to sit next to or work in groups with the bullies!
Once I left the hell hole, I got a mundane job and did my qualifications to A level via evening classes and self study, and then got my chartered accountancy qualification over the next five years, again by self study, distant learning and evening classes. I managed to turn it around.
It wasn't a lack of hard work at the crap comp - it was literally doing what I had to do to survive the five worst years of my life. I worked very hard for the subsequent 8-9 years to make something of myself and get the education I needed, alongside a full time job! That's hard work.
As others have said, if you're in a nurturing, stable, environment, then working hard or not makes a difference to your education. But if you're in a hostile environment, home or school, you're really not in a position to get a good education, whether you work hard or not as there are other factors preventing you from achieving.