Wrote the objective