We Americans love the stories where the rag-tag misfit underdogs win with instinct, guts and a montage.
That does happen, but usually it's the ones who put in the steady training who win.
Pretty much.
School is a "system" that you can navigate just like a job/career/bureaucracy. There's a list of idealized, vague, contradictory expectations out there that nobody meets, and then there's what you actually have to do to get what you want and keep the higher-ups happy.
A good student figures out study habits that work best for them, figures out what kinds of question to ask and how to ask them, to make sure that they are exactly sure what they need to do to get the grade they want with the minimum amount of effort. Then they go do it. Hopefully, they will find something interesting enough during the process to learn more about it on their own, but that's incidental to the "get good grades" goal.
At work, it's similar: "Okay, all that marketing speak is great, I want to make a website that brings venture capitalists to spontaneous orgasm too. But what's the ask here? Do you have a requirements document? What are our budget, deliverables, deadlines, and how many people do I get to do this?"
Some people figure out how to do that in school, and get good grades. Some people don't figure it out until later, so they have good careers in spite of their grades, but they'll always be a little behind the first group.
And, yeah, some people never figure it out.*
*Then again, some days, 36 hours a week of smoking pot in between doing oil changes doesn't seem like such a bad life.