So you want to prove the following theorem:
Theorem: If $\Gamma,\phi \vdash \psi$ and $\Gamma, \phi \vdash \neg \psi$, then $\Gamma \vdash \neg \phi$
Proof:
First, I'll assume that you can use the Deduction Theorem, which states that for any $\Gamma$, $\varphi$, and $\psi$:
If $\Gamma \cup \{ \varphi \} \vdash \psi$, then $\Gamma \vdash \varphi \rightarrow \psi$
So if $\Gamma,\phi \vdash \psi$ and $\Gamma, \phi \vdash \neg \psi$, then by the Deduction Theorem we have $\Gamma \vdash \phi \to \psi$ and $\Gamma \vdash \phi \to \neg \psi$
This means that if can show that $\phi \to \psi, \phi \to \neg \psi \vdash \neg \phi$, then we're there.
This is not easy, but here goes:
First, let's prove: $\phi \to \psi, \psi \to \chi, \phi \vdash \chi$:
\begin{array}{lll}
1&\phi \to \psi & Premise\\
2& \psi \to \chi & Premise\\
3&\phi& Premise\\
4&\psi& MP \ 1,3\\
5&\chi& MP \ 2,4\\
\end{array}
By the Deduction Theorem, this gives us Hypothetical Syllogism (HS): $\phi \to \psi, \psi \to \chi \vdash \phi \to \chi$
Now let's prove the general principle that $\neg \phi \vdash (\phi \to \psi)$:
\begin{array}{lll}
1. &\neg \phi& Premise\\
2. &\neg \phi \to (\neg \psi \to \neg \phi)& Axiom \ 1\\
3. &\neg \psi \to \neg \phi& MP \ 1,2\\
4. &(\neg \psi \to \neg \phi) \to (\phi \to \psi)& Axiom \ 3\\
5. &\phi \to \psi& MP \ 3,4\\
\end{array}
With the Deduction Theorem, this means $\vdash \neg \phi \to (\phi \to \psi)$ (Duns Scotus Law)
Let's use Duns Scotus to show that $\neg \phi \to \phi \vdash \phi$
\begin{array}{lll}
1. &\neg \phi \to \phi& Premise\\
2. &\neg \phi \to (\phi \to \neg (\neg \phi \to \phi))& Duns \ Scotus\\
3. &(\neg \phi \to (\phi \to \neg (\neg \phi \to \phi))) \to ((\neg \phi \to \phi) \to (\neg \phi \to \neg (\neg \phi \to \phi)))& Axiom \ 2\\
4. &(\neg \phi \to \phi) \to (\neg \phi \to \neg (\neg \phi \to \phi))& MP \ 2,3\\
5. &\neg \phi \to \neg (\neg \phi \to \phi)& MP \ 1,4\\
6. &(\neg \phi \to \neg (\neg \phi \to \phi)) \to ((\neg \phi \to \phi) \to \phi)& Axiom \ 3\\
7. &(\neg \phi \to \phi) \to \phi& MP \ 5,6\\
8. &\phi& MP \ 1,7\\
\end{array}
By the Deduction Theorem, this means $\vdash (\neg \phi \to \phi) \to \phi$ (Law of Clavius)
Using Duns Scotus and the Law of Clavius, we can now show that $ \neg \neg \phi \vdash \phi$:
\begin{array}{lll}
1. &\neg \neg \phi& Premise\\
2. &\neg \neg \phi \to (\neg \phi \to \phi)& Duns \ Scotus\\
3. &\neg \phi \to \phi& MP \ 1,2\\
4. &(\neg \phi \to \phi) \to \phi& Clavius\\
5. &\phi& MP \ 3,4\\
\end{array}
By the Deduction Theorem, this also means that $\vdash \neg \neg \phi \to \phi$ (DN Elim or DNE)
Finally, we can show the desired $\phi \to \psi, \phi \to \neg \psi \vdash \neg \phi$:
\begin{array}{lll}
1. &\phi \to \psi& Premise\\
2. &\phi \to \neg \psi& Premise\\
3. &\neg \neg \phi \to \phi& DNE\\
4. &\neg \neg \phi \to \psi& HS \ 1,3\\
5. &\neg \neg \phi \to \neg \psi& HS \ 2,3\\
6. &(\neg \neg \phi \to \neg \psi) \to (\psi \to \neg \phi)& Axiom \ 3\\
7. &\psi \to \neg \phi& MP \ 5,6\\
8. &\neg \neg \phi \to \neg \phi& HS \ 4,7\\
9. &(\neg \neg \phi \to \neg \phi) \to \neg \phi& Clavius\\
10. &\neg \phi& MP \ 8,9\\
\end{array}
Now, you can actually get a little more quickly to $\neg \neg \phi \vdash \phi$ as follows:
\begin{array}{lll}
1&\neg \neg \phi&Premise\\
2&\neg \neg \phi \to (\neg \neg \neg \neg \phi \to \neg \neg \phi)&Axiom \ 1\\
3&\neg \neg \neg \neg \phi \to \neg \neg \phi&MP \ 1,2\\
4&(\neg \neg \neg \neg \phi \to \neg \neg \phi) \to (\neg \phi \to \neg \neg \neg \phi) & Axiom \ 3\\
5& \neg \phi \to \neg \neg \neg \phi & MP \ 3,4\\
6&(\neg \phi \to \neg \neg \neg \phi) \to (\neg \neg \phi \to \phi) & Axiom \ 3\\
7& \neg \neg \phi \to \phi & MP \ 5,6\\
8&\phi&MP \ 1,7\\
\end{array}
However, since the proof of $\phi \to \psi, \phi \to \neg \psi \vdash \neg \phi$ relies on Clavius, I took the road that I did.
Best Answer
Just as an example of how to use the Deduction Theorem, let me do b)
First, let's show that $X, X \rightarrow Y \vdash Y$:
$X$ Premise
$X \rightarrow Y$ Premise
$Y$ MP 1,2
OK, so we have $X, X \rightarrow Y \vdash Y$
By the Deduction Theorem, we thus have $X \vdash (X \rightarrow Y) \rightarrow Y$
And applying the Deduction Thorem on that, we get $\vdash X \rightarrow ((X \rightarrow Y) \rightarrow Y)$
Now, the others aren't quite so easy, but here are some useful derivations thay may help:
Let's prove: $\phi \to \psi, \psi \to \chi, \phi \vdash \chi$:
$\phi \to \psi$ Premise
$\psi \to \chi$ Premise
$\phi$ Premise
$\psi$ MP 1,3
$\chi$ MP 2,4
By the Deduction Theorem, this gives us Hypothetical Syllogism (HS): $\phi \to \psi, \psi \to \chi \vdash \phi \to \chi$
Now let's prove the general principle that $\neg \phi \vdash (\phi \to \psi)$:
$\neg \phi$ Premise
$\neg \phi \to (\neg \psi \to \neg \phi)$ Axiom1
$\neg \psi \to \neg \phi$ MP 1,2
$(\neg \psi \to \neg \phi) \to (\phi \to \psi)$ Axiom3
$\phi \to \psi$ MP 3,4
With the Deduction Theorem, this means $\vdash \neg \phi \to (\phi \to \psi)$ (Duns Scotus Law)
Let's use Duns Scotus to show that $\neg \phi \to \phi \vdash \phi$
$\neg \phi \to \phi$ Premise
$\neg \phi \to (\phi \to \neg (\neg \phi \to \phi))$ (Duns Scotus Law)
$(\neg \phi \to (\phi \to \neg (\neg \phi \to \phi))) \to ((\neg \phi \to \phi) \to (\neg \phi \to \neg (\neg \phi \to \phi)))$ Axiom2
$(\neg \phi \to \phi) \to (\neg \phi \to \neg (\neg \phi \to \phi))$ MP 2,3
$\neg \phi \to \neg (\neg \phi \to \phi)$ MP 1,4
$(\neg \phi \to \neg (\neg \phi \to \phi)) \to ((\neg \phi \to \phi) \to \phi)$ Axiom3
$(\neg \phi \to \phi) \to \phi$ MP 5,6
$\phi$ MP 1,7
By the Deduction Theorem, this means $\vdash (\neg \phi \to \phi) \to \phi$ (Law of Clavius)
Using Duns Scotus and the Law of Clavius, we can now show that $ \neg \neg \phi \vdash \phi$:
$\neg \neg \phi$ Premise
$\neg \neg \phi \to (\neg \phi \to \phi)$ Duns Scotus
$\neg \phi \to \phi$ MP 1,2
$(\neg \phi \to \phi) \to \phi$ Law of Clavius
$\phi$ MP 3,4
By the Deduction Theorem, this also means that $\vdash \neg \neg \phi \to \phi$ (DN Elim)
Now we can prove $\vdash \phi \to \neg \neg \phi$ (DN Intro) as well:
$\neg \neg \neg \phi \to \neg \phi$ (DN Elim)
$(\neg \neg \neg \phi \to \neg \phi) \to (\phi \to \neg \neg \phi)$ Axiom 3
$\phi \to \neg \neg \phi$ MP 1,2
Now we can derive Modus Tollens: $\phi \to \psi, \neg \psi \vdash \neg \phi$:
$\phi \to \psi$ Premise
$\neg \psi$ Premise
$\neg \neg \phi \to \phi$ DN Elim
$\neg \neg \phi \to \psi$ HS 1,3
$\psi \to \neg \neg \psi$ DN Intro
$\neg \neg \phi \to \neg \neg \psi$ HS 4,5
$(\neg \neg \phi \to \neg \neg \psi) \to (\neg \psi \to \neg \phi)$ Axiom3
$\neg \psi \to \neg \phi$ MP 6,7
$\neg \phi$ MP 2,8
By the Deduction Theorem this gives us $\phi \to \psi \vdash \neg \psi \to \neg \phi$ (Contraposition)
And if we apply the Deduction Theorem on Contradiction, we get $\vdash (\phi \to \psi) \to (\neg \psi \to \neg \phi)$.
Finally, we can prove $\phi \to \psi, \neg \phi \to \psi \vdash \psi$:
$\phi \to \psi$ Premise
$\neg \phi \to \psi$ Premise
$\neg \psi \to \neg \phi$ Contraposition 1
$\neg \psi \to \psi$ HS 2,3
$(\neg \psi \to \psi) \to \psi$ Law of Clavius
$\psi$ MP 4,5
Now we can apply the Deduction Theorem twice, and get:
$\vdash (\phi \to \psi) \to ((\neg \phi \to \psi) \to \psi)$