Final answer:
The housing units described as having several attached units with shared walls, as well as individual front and rear doors and yards, are collectively known as townhouses.
Step-by-step explanation:
The type of housing described in the question, where several units are attached to each other with shared walls between the units, and each unit having a front and rear door and yard, are collectively called townhouses. Townhouses are a popular form of residential architecture that offer a sense of community living while also providing private living spaces for each family or individual. They contrast with other housing types like apartments, which are typically units in a larger building with shared common spaces but not individual exterior doors or yards, and mansions, which are large, single-family private homes.