first I'd suggest finding the percent mass in the original sample of hydrogen by finding the mass of the hydrogen in the resultant water, then dividing that number by 299.0. Once you have that number, you'd find the percent of hydrogen in each of the compounds and write equations that would have it average out to the hydrogen in the whole sample.

That's a fairly vague explanation, but hopefully it will lead you in the right direction. Naturally, if you have a question, ask.