A hydrocarbon is a compound made of hydrogen and carbon atoms only. Fuels such as methane, propane and petrol are hydrocarbons, and they burn by reacting with oxygen. When there is plenty of oxygen the burning is called complete combustion.
In complete combustion all the carbon in the fuel becomes carbon dioxide and all the hydrogen becomes water. For methane: CH4 + 2O2 → CO2 + 2H2O. The reaction also gives out energy, mostly as heat, so combustion is an exothermic reaction.
You can test for the two products. Cool the gases from a burning fuel and water condenses; it turns white anhydrous copper(II) sulfate blue. Bubble the gases through limewater and the limewater turns cloudy, which shows carbon dioxide is present.