They're smart enough not to invest billions into markets where they have no particular expertise, but make bets that play to their strengths, instead.
Apple in particular. It's easy to forget it wasn't long ago that the Mac was the lion's share of their revenue. iPod, iPhone, iPad have all added revenue and profits from day one.
The same can't be said for Microsoft's attempts to expand into new markets. Which is why Apple surpassed them in market cap, which still sounds ridiculous to me remembering what the situation in the 90s.
http://blog.rescuetime.com/2010/06/17/google-is-eating-micro...
This article shows the number of Office online users in just the first 100 days after launch as 20 million, compared to 25 million for Google Apps.
http://seattletimes.nwsource.com/html/microsoftpri0/20130869...
http://www.betanews.com/joewilcox/article/Microsoft-Windows-...