How many people does an engineer making 400k have to manage?
In both cases the work was difficult to do, difficult to share across a team (solve a few hard problems well rather than cycle through hundreds of small JIRA tickets) and highly value adding for the company which is why they were willing to pay.