The gap is not even close. Walmart sells almost $500 billion in goods every year in the US alone. Amazon sold less than $200 billion in 2017. You could fit more than 2 Amazon.com's into Walmart. This is admitted by the article halfway down but a lot of people don't really take this into account when they think about Amazon.
Amazon may be a very exciting stock, but it is not the leading retailer. It is only the dominant retail website online, and that dominance in market share is actually quite misleading because the Amazon Marketplace is not a 1:1 comparison with how Walmart retail stores work. The Amazon Marketplace is hundreds of thousands of independent retailers daisy chained together to supply the website with valid, high quality offers combined with a small number of conventional vendor suppliers. Walmart is Walmart. When you buy from Walmart you buy from Walmart (unless it's through the online Walmart Marketplace which aspires to be an Amazon Marketplace clone).
Amazon has had some breakout successes in entirely different markets from retail, like their leading cloud business.