Stocks traded in a narrow range on low volume Thursday, with major benchmarks closing with mixed results as investors look forward to trade news from the G-20 meeting this weekend. The Dow Jones Industrial Average (DJINDICES:^DJI) posted a small loss and the S&P 500 (SNPINDEX:^GSPC) gained ground. Financials led the market, while energy was the only sector that fell.

Today's stock market

Index Percentage Change Point Change
Dow (0.04%) (10.24)
S&P 500 0.38% 11.14

Data source: Yahoo! Finance.

As for individual stocks, Walgreens Boots Alliance (NASDAQ:WBA) reported strengthening sales in the U.S., and KB Home (NYSE:KBH) saw robust order growth.

Wall Street sign in front of New York Stock Exchange.

Image source: Getty Images.

Domestic sales improvements boost Walgreens

Gains in Walgreens' U.S. pharmacy sales offset weakness in retail and in Boots stores in the U.K., and the stock rose 4.1% after the company's fiscal third-quarter results beat expectations. Sales increased 0.7% to $34.6 billion and adjusted earnings per share fell 4% to $1.47. Analysts were expecting the company to earn $1.43 per share on sales of $34.5 billion.

Pharmacy comparable sales grew 6%, a big improvement over the 1.9% gain last quarter, but gross margin fell 1.5 percentage points due to continued pressure on reimbursements. Comparable front-end retail sales dropped 1.1%, but that was also an improvement over a 3.8% decline last quarter. Comparable retail sales in the U.K. fell 2.6% in constant currency but pharmacy sales at Boots UK rose 0.8%.

Walgreens, coming off a terrible Q2, continues to integrate Rite Aid stores and close underperforming stores in the U.S. and the U.K., all while facing reimbursement headwinds. Investors were encouraged by improving domestic sales performance today, though.

KB Home constructs a better-than-expected quarter

Investors were braced for more bad news from the homebuilding industry, but KB Home instead exceeded expectations for the second quarter and shares jumped 7.9%. Revenue fell 7.2% to $1.02 billion, beating the analyst consensus of $936 million. Earnings per share dropped 8.9% to $0.51, but Wall Street was expecting a 30% decline to $0.40.

Homes delivered increased 2% to 2,768, but the average selling price decreased 8% to $367,700 due to a shift to lower-cost communities. Housing gross profit margin adjusted to exclude inventory-related charges and amortization was 21.3%, steady from the previous quarter. Net orders grew a whopping 15% year over year.

On the conference call, KB Home said that sales strengthened from March to April to May, and that a higher backlog will improve revenue growth and profitability heading into 2020. It expects gross margin to improve 0.7 to 1.3 percentage points in Q3 compared with Q2, and further improvement in Q4. KB Home competes at the lower end of the price scale, and a shortage of homes for first-time buyers is creating solid market conditions for the company.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.