Let formula of hydrocarbon =CxHy
Volume of hydrocarbon taken =10mL
Volume of oxygen gas added =80mL
Combustion of hydrocarbon-
CxHy+(x+y4)O2⟶xCO2+y2H2O
From the above reaction-
1 mole of CxHy reacts with (x+y4) mole of O2 to produce x mole of CO2.
Therefore by avogadro's law-
1 mL of CxHy reacts with (x+y4) mL of O2 to produce x mL of CO2.
10 mL of CxHy reacts with 10(x+y4) mL of O2 to produce 10x mL of CO2.
Therefore,
Volume of residual gas (CO2+unused O2)=70mL
Since KOH absorbs whole CO2 and volume of gas left after KOH treatment is 50 mL
Volume of CO2 formed =70−50=20mL
From the above reaction of combustion of CxHy-
10x mL of CO2=20 mL of CO2
x=2010=2
Now,
Volume of unused O2=50mL
∴ Volume of O2 used 4=80−50=30mL
Again from the above combustion reaction-
10(x+y4)=30
2+y4=3
⇒y=4
Hence the molecular formula of hydrocarbo will be CxHy=C2H4.