Dollar General is slashing prices, becoming the latest retailer to try to woo inflation-weary shoppers.