When an acid reacts with metals, salt and hydrogen gas are produced.
Metal is always a positive element so, when it is reacted with an acid, the negative part will attach to the metal.
But, not all metals react to the acids in the same way.
The metals present below the hydrogen in the reactivity series(a list of metals arranged in decreasing order of their reactivity) do not react with acid as the reaction will not be feasible.
For example, zinc powder reacts with hydrochloric acid () that releases gas and zinc chloride ()
This is a single displacement reaction where the anion from the acid recombines with the metal to form the salt In this case, and ions form and hydrogen gas is released.