The few that didn't were the ones that either got into harder drugs or were already also stealing or hanging out with gangsters also.
The people that just sat around smoking weed though for the most part ended up alright.
I didn't smoke weed through high school but I still did poorly because I didn't really care. I was more concerned with my mom slowly dying of lung cancer at the time. I did enough to pass but was about it. High school was honestly one of the most pointless things i've had to do in my life. It didn't stop me from going to school after and doing useful things with my life though. I also smoked weed constantly throughout university and was consistently among the top in my class. I'd be stoned during midterms and get 100% or more on a couple occasions.
I've never found it slows me down or stops me from thinking. If anything it does the opposite. It lets my mind focus on one thing at a time without getting distracted and makes tasks i'd othwerwise find boring and probably procrastinate on fun and interesting and gives me more incentive to do those things.
I know plenty of people that spent high school and even a not insignificant amount of college in a pot-induced daze that are successful developers, scientists and even one doctor.