The barriers to entry of learning to code are falling dramatically though. When I was a kid having a computer that cost several thousand dollars was table stakes, and even then in practice most of the kids who got beyond basics had parents who were also engineers.
These days a good enough computer costs less than $500, and in the last five years the free resources on the web have gotten good enough that anyone can teach themselves without needing any expensive classes. At most you might need another couple hundred dollars worth of books. At this point English literacy is probably a bigger barrier to entry than the monetary cost.