The answer is NiCl3.
Solution:
We can convert the masses of the elements to the number of moles using their atomic masses:
moles of Ni = 0.587g Ni * 1mol Ni/58.6934g Ni = 0.01000 mol
moles of Cl = 1.065g Cl * 1mol Cl/35.453g Cl = 0.030040 mol
We divide the number of moles of each element by the lowest number of moles. In this case, we divide by 0.01000:
0.01000 mol Ni / 0.01000 = 1
0.030040 mol Cl / 0.01000 = 3.004 ≈ 3
We can now write the empirical formula of nickel chloride using these values as the subscript for each element: NiCl3