Sales of existing homes rose in July, surpassing expectations, as buyers snapped up deeply discounted properties in areas hit hardest by the housing bust. But the number of unsold homes hit a high — evidence that the worst housing slump in decades is far from over. Prices nationwide aren't expected to hit bottom till early next year. The National Association of Realtors said sales rose 3.1%, to a seasonally adjusted annual rate of 5 million units, up from June's downward-revised annual rate of 4.85 million units. July sales had been expected to rise by only 1.6%, according to economists surveyed by Thomson/IFR. Sales were about 13% lower than a year ago, and prices were off sharply. The median price of homes sold in July (half sold for more, half for less) fell to $212,000, 7.1% from July 2007. Despite the third monthly sales increase this year, the number of unsold single-family homes and condominiums rose to 4.67 million, the most since 1968, when the NAR started tracking the data. That was an 11.2-month supply at the July sales pace, matching the all-time high, set in April. Until the supply is reduced, analysts say, the housing slump is likely to persist. The inventory is being swelled by a wave of mortgage foreclosures: 33% to 40% of sales activity is coming from foreclosures or other distressed properties, estimates Lawrence Yun, NAR chief economist. Though buyers are pouncing on lower prices — especially in such states as California, Florida and Nevada — sales are weak in states such as Texas. "People are responding to lower prices," Yun says, but there's "too much uncertainty" about the housing market's future to mark a definite bottom. In Las Vegas, sales were 96% higher in July, after prices fell more than 25%, to a median of $220,000, according to The Associated Press-Re/Max Monthly Housing Report, which analyzed sales recorded by real estate agents in 55 cities, regardless of company affiliation. Sales in Los Angeles were up 31% after prices fell 35% over the past year, to a median of $335,000, according to the AP-Re/Max report. In Miami, sales were up 9%, while prices dropped nearly 10%, to a median of $280,000. One of those sellers last month was Jennifer Del Pino, who unloaded her 3,600-square-foot Miami home to a buyer from Germany for $490,000. Having cut her asking price by $60,000, she sold her house in about a month. One unknown for the housing market is the future ability of Fannie Mae and Freddie Mac to supply money for loans. The two government-sponsored mortgage giants have sharply cut back their mortgage activity as they cope with rising losses from foreclosures. Copyright 2008 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed. Guidelines: You share in the USA TODAY community, so please keep your comments smart and civil. Don't attack other readers personally, and keep your language decent. Use the "Report Abuse" button to make a difference. You share in the USA TODAY community, so please keep your comments smart and civil. Don't attack other readers personally, and keep your language decent. Use the "Report Abuse" button to make a difference. Read more