Most of the 20 cities where owners gained the most upon selling their homes during the third quarter were in California . Most of the cities where homeowners gained the least were in the south,