Given,
W=mg
The acceleration due to gravity, g=9.8 m/s²
Let us assume that the weight is W Newtons.
The weight is the product of the mass and the acceleration due to gravity. Thus, in the above equation m is the mass.
Thus on rearranging the given equation,
On substituting the known values,
Thus the mass is given by W/9.8, where W is the value of the weight.