Tips to avoid buying a problem house

Purchase contingency, written defect disclosure are vital