In pig iron, from where does carbon in it comes from?
A blast furnace is made of successive layers of charcoal and iron oxide mineral. In the beginning, the lower layer of charcoal is lit and the fire is maintained by air being pressed through the burning matter. The combustion produces first $CO_2$. But as the temperature is high and the charcoal is in excess, $CO_2$ soon reacts with $C$  producing $2$ $CO$  according to the equations :$$\ce{C + O_2 -&gt; CO_2}$$ $$\ce{CO_2 + C -&gt; 2 CO}$$ Then the CO gas touches the bits or pieces of mineral, which produces the following equation :$$\ce{3 CO + Fe_2O_3 -&gt; 2 Fe + 3 CO_2}$$ This produces some metallic iron which is liquid if the temperature is high enough. This liquid flows between the bits of burning charcoal, and dissolves some charcoal during this flow. The obtained pig iron contains about 5% carbon. which must be later on burned in special furnaces, to get steel (containing about 1% dissolved carbon)