Mixture of Fe and S , when treated with dilute sulphuric acid, hydrogen gas is produced by the reaction of Fe and H2SO4.
Fe + H2SO4 → FeSO4 + H2
But when this mixture of Fe and S is heated, a new compound is formed , FeS. FeS is black coloured solid, which then reacts with H2SO4 to produce hydrogen sulphide gas.
FeS + H2SO4 → FeSO4 + H2S
At two different temperature, these reactions are different because different species are reacting with sulphuric acid.
In mixture, iron show individual properties therefore displace H2 gas from acid where as when heated iron loses its properties and form FeS which reacts with acid to produce H2S.