Deductions & credits

Yes, each couple will file a joint return. Since we sold our house that had 4 owners (2 married couples), do both couples get that $500,000 exclusion?