Before the reaction occurs, you are given the volume of gas, the temperature, and the pressure. From this information, you can find the number of moles of gas in the container (remember to account for both the volume of the liquid water, and the partial pressure of the water vapor). Using this number and the fact that the ratio of H2:O2 = 3:2, you can figure out the initial number of moles of hydrogen and oxygen.