HW done, very tedious