Fair point. I'd argue that youtube has way higher network effects than an ecommerce shop and that Google paid a comparatively smaller 1B$ for a richer global market than the 16B$ that Walmart paid to grab a bite of the Indian market, especially with the political risk involved. I'll also wager that Walmart could've spent a lot less by getting exclusive deals on new smartphones along with deep discounts to quickly grab a huge chunk of the marketshare.
I could be wrong. With the absurd amounts of QE that went on for so long, maybe valuations that price in earnings decades away are justifiable.