How to show that this argument is valid?
$(\exists x) [p(x) \to q(x)] \to [(\forall x) p(x) \to (\exists x) q(x)]$
I started by showing that $\exists$x [p(x) $\to$ q(x)] is the premise. But I don't know how to use the laws of logic (Modus Ponens, etc) to set this up. The only hint I have is step 2 is "existential instantiation", yet that word was not mentioned in that class.
We can prove it with Natural Deduction :
1) $∃x [p(x) → q(x)]$ --- premise [a]
2) $∀x p(x)$ --- premise [b]
3) $p(a) \to q(a)$ --- assumed [c] for $\exists$-elimination [in Natural Deduction this rule replace Existential instantiation]
4) $p(a)$ --- from 2) by $\forall$-elimiantion [i.e. Universal instantiation]
5) $q(a)$ --- from 3) and 4) by $\to$-elimination [i.e. Modus ponens]
6) $\exists x q(x)$ --- from 5) by $\exists$-introduction followed by $\exists$-elimination from 1) and 3), discharging temporary assumption [c]
7) $∀x p(x) → ∃x q(x)$ --- from 2) and 6) by $\to$-introduction, discharging premise [b] [i.e. Deduction theorem]