When God told Abraham that he was going to destroy Sodom and Gomorrah, Abraham nearly talked him out of it. He got God to agree that if ten righteous men were found in the cities, he would not destroy the cities for their sakes.
Abraham quit reasoning with God after getting to him to agree to ten. I think Abraham felt there where ten righteous men there. But he was wrong. Ten were not found, only one, and Sodom and Gomorrah were left as smoking ruins (if there were any ruins left to smoke).
Why did God, you suppose, agree to save this city for ten people? When one righteous man was found, he got him and his family out of the city. If there had been ten righteous men, he could have just gotten them out of the city, as well. So, why did God respond to Abraham the way he did?