You're assuming that the degree has anything to do with the work. The vast majority of things I've been paid to do in the course of my life have had little to do with the subjects of my degrees. That said, because I have a bachelor's in English and master's in Math Education and Fiction Writing (two separate degrees, not one weird interdisciplinary one), there are fields that I cannot hope to break into. No one will hire me to be their chemist or auto mechanic with my credentials. Programming is probably the easiest field for someone with no paper credentials to get into out of all the highly paid careers.
And this is why I went the way that I did. Unfortunately, I'm from what's practically extreme poverty in the U.S., I'm sure a large amount of Mech and Elec EE's (or engineers in general) aren't exactly from upper class wealth...
And, guess what. I'm young, the planet is on fire and only getting worse, and it's beyond obvious that nothing is going to change that within my lifetime. That's a singular of many issues. The only way to insulate yourself from a lifetime of suffering from this is by money, and lots of it. Definitely not with what even senior ME's or EE's make.
To imagine a young student would choose to go one route because it's fun or their passion instead of a route that will somewhat secure their future at this point is asinine, and it's going to completely fuck industry over (as if it's not already) when there's a lack of capable engineers in other disciplines than SWE
SWE is one of the most difficult professions at the highest levels. If it's so simple, then the ready supply of SWE should depress wages but that is clearly not happening.
The issue is that 99% of senior other engineering professions top out at like, $160-$175k at most.
You can be fresh out of college, go to an absolutely entry level junior SWE job, and make $250k.
There lies the issue.
I would also argue EE is more difficult at the highest than SWE. There's some deeply rooted knowledge, logic, and physics required, whereas in SWE... at the highest levels, you can almost pave your own damn path however you choose to and make things work.
The studies for ME or EE are hard, but are those jobs harder? SWEs handle ungodly amounts of complexity, trying to build and keep running a system based on poorly documented libraries, shitty third-party services, code that was written a long time ago and no one understands it, backcompat requirements, availability and scalability requiremets etc. etc. There's a ton of stuff to juggle in your mind, whereas an EE or ME can just work on button for a car cockpit or something.
The EE/ME equivalent of what you're talking about for SWEs is not "work on button for a car cockpit or something" -- it's hardware/software/enclosures for things like space-hardened applications and payloads, industrial and commercial applications, or medical devices. Some of these are hellishly complex systems, others are just hellishly out of date, over-budget, poorly documented, and "shitty third-party [i.e. lowest-bidding contractor] services".
If you want to tell an EE or ME to just go work on buttons for a car cockpit, you might as well go tell an SWE that they can just go write AJAX calls to update HTML elements on a page, or update Wordpress plugins for businesses.
The electrical and mechanical engineering fields have far advanced past "button for a car cockpit" into much more complex domains, just like SWE has advanced far past writing vanilla JS to update HTML elements into things like JS frameworks, containers, (P/I/S)aaS.
You don't particularly seem to have the best grasp on the breadth of a career in ME/EE
Furthermore... if you're going to give an example, please don't make it one of the most beauracratic red taped government jobs program. Yes, we all know what happens at Boeing is not exactly contributing much to society nor giving fulfilling jobs at this point. Entry level Google doesn't particularly do so either, but you can start $200k w/great benefits & all you have to do is have enough accreditation to get thru initial resume screening (which is not much) and then have grinded leetcode for a few months.
I won't touch on any of the other points, but I'd repeat something I've said to many junior engineers over the years.
I'd agree that the barrier to entry to SWE is probably lower. There's a ton of work where you just need anyone with two hands and a brain to smash their fingers into the keys until someone's idea is realized, but to get to the upper echelon of the field, it's at a minimum on par with any of the other engineering fields out there.
But instead you can get a good job doing things the machine could certainly do, and do better, but doesn't yet because nobody yet taught a machine how. It's unclear how long that will last, but it may well be enough that everybody reading HN has retired before it's over. At the beginning of my career printf("This %p is %d a %s bad %n idea\n") didn't produce a compile error. In 2020 the C++ Standard Library specification still didn't say that the equivalent mistake was a compile error (but in 2021 they retrospectively fixed the 2020 standard to say it is), and I'd say this is now the middle of my career.
Progress has been slow is what I'm suggesting.
Software engineering is in a similar bubble right now thanks to gigantic influxes of VC cash trying to will future monopolies into existence, or at least convince the public markets at some point they've got a decent shot so they can cash out on exit, by undercutting service prices and overpaying developers to keep them from working anywhere else.
Whether it lasts or also comes crashing down we'll see, but historically, every bubble has tended to burst eventually. It's kind of hard to know in advance what the next one will be, especially as a teenager when you're still in a position to tailor your life's educational and career plans to trying to be inside of it when it happens.
In the end, the pay for both of those careers is kinda complete shit for what you do to get the degree, unless you manage to happily completely bullshit yourself through everything and don't let it weigh on your conscience.
SWE is... arguably easier than both Mech E and Elec E in my mind, and the option for remote work has always been much, much higher. And the starting pay is... about 2.5x more, at a minimum, to begin with - and if you want to be a dick, and know how to interview FAANG and the like, you can hop company to company, do basically nothing and make that pay for 4-6 months before you're found out. And not to mention the benefits...
I can't understand why there's not more of an outrage. It's insane. I simply can't tell any high schooler that an engineering degree outside of SWE, and maybe a highly focused aerospace degree, is worth it for the foreseeable future.