Take a look at NPR's "What you'll Actually Pay At 1,550 Colleges" [0]. To pay $40k at a good school you'd have to be pretty wealthy ($110k+ household income). At median income, good but not Ivy League private schools (UChicago, Columbia, CalTech, MIT) are running $8-12k.
[0] http://www.npr.org/sections/money/2015/09/30/444446022/what-...