Density of solution `= 1.17g/(ml)` .
Mass of 300ml of solution `= 1.17xx300=351g`
Since the % of Mg in `MgCl_2` is 5.1%
Mass of Mg in the solution `=351xx5.1/100=17.901g`
Molar mass of Mg `= 24.3g/(mol)`
Amount of Mg moles `=17.901/24.3 =0.737`
Amount of `Cl^-` ions `=2xx0.737 =1.474`
So the amount of Chloride ions in 300ml of solution is 1.474mol.