Unfortunately, this isn't how finance works, so I can't hire you as CEO.
Yahoo has $1.5Bn in cash. Companies usually get bought for cash and stock that the company owns, or they can issue more stock if it's a merger that gets broad approval. YHOO doesn't have $20Bn to buy companies with, and if they did, they still couldn't make the investments you're talking about. Twitter alone is worth $8.5Bn on the secondary market... It would sell for more than $10Bn. And buying the New York Times for $1.5Bn would incur another bil in debt.