Tendrás que estudiar necesariamente si quieres aprobar el examen.

You will necessarily have to study if you want to pass the exam.