On one street there are 4 houses next to each other in which four families live. The Vázquez family lives next to the Pérez family but does not live with the Martínez family ...
If the Martínez family does not live next to the Alvarez family,
Who lives with the Álvarez family?
The Álvarez family lives together with the Vázquez family.
According to the statement, the distribution of families in the four houses can be one of the following:
Álvarez - Vázquez - Pérez - Martínez
Martínez - Pérez - Vázquez - Álvarez
In both cases the Álvarez family is at one of the extremes with the Vázquez family.