The mass of water is obtained by subtracting the mass of the compound after heating from the mass before heating.
2.78 - 1.52 = 1.26 g which is the mass of the water in the compound
The number of moles of the water is given by 1.26 g / 18 g/mole = 0.07 moles.
The number of moles of anhydrous FeSO4 is 1.52 g / MM FeSO4 = 1.52 / 152 g/mole = 0.01 moles FeSO4.
The ratio of moles water to moles FeSO4 is 0.07 / 0.01 or 7/1.
Therefore, the molecular formula of the hydrate is FeSO4 • 7H2O.