Function boardEquals