I've been doing that for a few years now and I'm at ~1.6M all liquid and on track to retire before I'm 40 (32 now) and I'm a standard software engineer working in infra. I wish I would have known that earlier instead of completely wasting my time working as a startup employee for pennies, but I also had immigration issues (H1B visa) that prevented me from freely navigating the job market (or at least that's what I like to tell myself as a poor excuse for not taking more control of my future sooner...).
If you want to reduce those ~5 years, you can start putting your money in speculative bets (e.g. crypto, leveraged etf, option trading), but that's not my cup of tea, I am way too aware of how much easier it is to go from $1M to $0 than from $0 to $1M.
The biggest advice I have for you is: if you're interested in seeing financial returns on your time/work, don't work for a startup, ever :-)
350K - 500K sounds insane for a run of the mill developer.
Many of my friends are developers who know Python (and just Python), have no deep understanding of underlying computing fundamentals (no network stack, no operating systems, ...) and no special skills (no big data, no machine learning, ...). They all still managed to get a really good offer from FAANG (in the same range I'm mentioning), they just had to pass the typical coding interview puzzles that are really not that difficult if you spend a few weeks seriously training for them.
One thing to keep in mind: Bay Area is massively expensive, so don't disregard my other point of being "very frugal": it is very easy to end up spending 150-200k after tax in cost of living, especially if you feel you "deserve" nice stuff, or you have kids. I grew up poor in a poor country, so living like a student at 32 still feels like luxury to me (I drive a brand new Honda Civic, live by myself, cook good food at home, ...) and allows me to save 200k+ a year, but many people wouldn't be able to do it In the Bay. Many of my peers routinely spend $600+ a month just on Uber Eats/Doordash, which is simply insane to me.
$103k is the low end. $153K is high end.
350k-500k/year is not a typical salary at all, and only a tiny fraction of people would be able to manage to land a position that pays so well.
A talented developer could manage to make 200k-300k with the right experience.
The most surefire way is to work at a FAANG for ~10 years and keep your expenses under control or work your way up to an executive/partner position in a medium-sized business, but that's clearly not super fast.
The fastest way is the roulette wheel mentioned in another comment or the lottery, but that is realistically almost never going to pan out.
Entrepreneurship is IMO a good middle ground between the two paths.
Create value.
In that case he would only need 3 spins or so, assuming the casino doesn't shut him off and he doesn't mind paying taxes of like 500k on the earned income.
If there's no other variable besides "fastest", then robbing someone who has $1,000,000 cash under a mattress somewhere would be the "fastest", despite being extremely unethical and a considerable time sink to find someone with that much cash lying around.
Once you start winning big casinos will do anything to make you stay since they will, in the end, win it all back if you do.
1) Bet $1, hit the number, win $35.
2) Bet all $35, hit the number, win $1,225
3) Bet all $1,225, hit the number, win $42,875
4) Bet all $42,875, hit the number, win $1,500,625