Implementation until step4