At first glance these two retailers look almost identical -- even interchangeable -- from an investor's perspective. Dollar General (DG -0.59%) runs small, localized, value-oriented stores. So does Dollar Tree (DLTR -0.16%). However, the two outfits are more different than they may seem on the surface. Indeed, an investor is likely to earn better returns owning a stake in one of these companies than the other.

Don't misread that message. Either of these discount store chains would make for a decent investment. That's particularly true in the current economic environment marked by inflation, which has consumers pinching a few more pennies than they normally might. If you happen to own the one that's not the "better buy," it's not necessarily a call to sell your existing position and use the proceeds to purchase the other stock.

If you're mulling a new position in one or the other, though, Dollar General's arguably got more upside potential. Three reasons stand out among all of its competitive edges.

1. Dollar General has a large (and growing) fleet of its own trucks

Family Dollar has its own delivery trucks -- but it's not like Dollar General's fleet. Dollar General owned around 1,600 tractor semi-trailers (or "rigs") as of the end of last year, with plans to own more than 2,000 by the end of this year. With that growth, the company will be handling roughly half of its own merchandise deliveries to its stores.

The upside to taking on this logistics work that's often delegated to third-party service providers is two-fold. First, it gives you better control over when and how deliveries of merchandise to stores are handled. Second, it's just cheaper, even if managing it is a bit of a headache. As CEO Jeff Owen pointed out during the quarterly conference call held earlier this month, the switch from third-party logistics service providers to in-house deliveries saves the company about 20% on its outbound shipping costs.

Meanwhile, Dollar Tree is currently "experiencing higher costs and disruptions in our distribution network," which make "an adverse impact on our sales, margins and profitability," according to 10-K filings from the company.

2. Dollar General has an expanding selection of fresh groceries

A selection of chilled and frozen packaged foods has been available in most Dollar General stores for years now. But more and more of its locales are adding non-refrigerated perishables like fruit and vegetables. As of the end of 2022, fresh produce was offered at more than 3,200 stores, with more on the way. Eventually, the retailer aims to offer fresh fruits and vegetables at more than 10,000 of its current 19,104 stores.

This matters for one overarching reason: While not a major profit source in and of itself, fresh produce brings people into the company's stores that may not otherwise enter a Dollar General store. Once there, they may end up purchasing other goods.

Dollar General can also provide the shipping speed needed to make perishables a viable business, rather than letting fresh fruits and vegetables spoil on a truck or on a warehouse. In addition to its large fleet of owned rigs, the retailer also operates 12 different cold-storage warehouses peppered across the county to make sure its fresh produce is still actually fresh once it gets to a store.

A select number of Family Dollar stores also now carry fresh fruits and vegetables, for the record. But it's a minimal amount of exposure to this sliver of the grocery market; the initiative still looks more like an experiment than a full-blown program.

3. Dollar General has a tighter, singular focus

Last but not least, Dollar General is a better buy than Dollar Tree due its tighter focus and less restrictive operations.

See, Dollar Tree isn't just the Dollar Tree chain. It's also the parent to Family Dollar, which accounts for roughly half of the company's 16,000-plus locales. Dollar Tree and Family Dollar are dramatically different venues, though. Family Dollars are more akin to Dollar Generals, selling goods at a variety of price points that make sense for the item in question. Dollar Trees, meanwhile, are largely limited to goods now priced at $1.25 after a modestly well-received price increase from its previous, singular price point of $1 for everything it sells; a few Dollar Tree stores are even finding some success selling merchandise with $3 and $5 price points.

That's great, and it's necessary. Inflation is unavoidable. It was always only a matter of time before the Dollar Tree chain was forced to raise its prices. At the very least these stores have proven their customers will digest some price hikes.

Nevertheless, each price increase above and beyond $1 pushes at least half the company's stores further away from the schtick it's been training customers to love since Dollar Tree's launch back in 1986.

Dollar General doesn't face such a branding restriction. While it is piloting a different store chain called Popshelf, these stores are simply more carefully curated venues selling goods at a variety of price points to urban consumers with above-average incomes. This doesn't require a merchandise sourcing approach that's sweepingly different than the one used for the Dollar General banner.

Being better doesn't make Dollar General bulletproof, but...

Keep it all in perspective. Being better equipped than a key competitor doesn't inherently mean that a superior company can do no wrong. Dollar General has its fair share of challenges too.

In an economic environment that plays right into the hands of all value-minded retailers, though, Dollar General has much more room to maneuver than its primary rival does. This flexibility covers everything from pricing to merchandise assortment to delivery logistics. In time, these little things can collectively add up to one very big thing -- like a bigger bottom line.