Finding the formula of a hydrated salt is no different than determining the empirical formula of any other compound – we are simply treating water as a stand alone unit in the formula, rather than breaking it down into the elements hydrogen and oxygen.
If you are not familiar with the standard practical for finding the water of crystallisation for a hydrated salt, you should watch this demonstration first.