First, we shall write the axioms in the following way:
$$I: a → a,\quad K: a → b → a,\quad S: (a → b → c) → (a → b) → a → c,$$
adopting the usual convention that bracketing occurs to the right, i.e. $a → b → c = a → (b → c)$.
Second, given proofs $f: a → b$ and $g: a$, we shall denote the application of modus ponens as $f g: b$, adopting the usual convention that bracketing for products occurs to the left, i.e. $fgh = (fg)h$.
This is motivated by the Curry-Howard Correspondence. As part of that correspondence we note that the following equivalences of proofs:
$$I x = x,\quad K x y = x,\quad S x y z = x z (y z),$$
which you can verify by writing each set out, using the conventions just described.
The deduction theorem, under this correspondence, asserts that if $f x = g x$, where $x$ is independent of $f$ and $g$, then $f = g$. This corresponds to the η-rule, or "extensionality". In particular, we note that
$$S K x y = K y (x y) = y = I y,$$
therefore $S K x = I$, for any $x$. The usual choice made is $x = K$, with $I = S K K$ taken as a definition. When written out as a proof, $S K x$ takes on the form
$$\begin{align}
S:& (a → b → c) → (a → b) → a → c,\\
K:& a → b → a,\\
S K:& (a → b) → a → c,\\
x:& a → b,\\
S K x:& a → c,
\end{align}$$
where the constraint $a = c$ arises from making $S K$ fit to modus ponens in the third step; thus yielding the result $S K x: a → a$.
Other useful theorems may be established similarly as follows:
$$
B = S (K S) K: (b → c) → (a → b) → a → c,\\
C = S (B B S) (K K): (a → b → c) → b → a → c,\\
W = S S (K I): (a → a → b) → a → b,
$$
with the corresponding equivalences
$$B x y z = x (y z),\quad C x y z = x z y,\quad W x y = x y y,$$
derivable from the definitions.
We can do composition with $B$, noting that if $φ: α → β$ and $ψ: β → γ$, then $B ψ φ: α → γ$. We can also use $C$ as an operator two swap the order of hypotheses, so that if $φ: α → β → γ$, then $C φ: β → α → γ$. This can be used to reverse the order of composition, as: $CBfg = Bgf$.
We can also use $B$ on a single argument to extend an implication to the right. Thus, if $φ: α → β$, then $Bφ: (γ → α) → γ → β$. To extend to the right, we use $CB$ instead: $CBφ: (β → γ) → α → γ$. Note that this reverses $α$ and $β$ since they're now on the "negative" side of the implication operator "$→$".
The additional axiom will be denoted
$$Z: (¬a → ¬b) → b → a.$$
For the following, the definition $¬a = a → ⊥$ won't be needed. The rule of contradiction is, effectively, given by
$$V = B Z K: ¬a → a → b,$$
and the double-negative rules are given by
$$N = S (B Z V) I: ¬¬a → a,\quad Z N: a → ¬¬a.$$
The result you're seeking is
$$f: a → b → a ∧ b = ¬(¬a ∨ ¬b) = ¬(¬¬a → ¬b).$$
This can be written as a composition with $Z$: $f = B g Z$, where
$$g: a → ¬¬(¬¬a → ¬b) → ¬b.$$
In turn, this can be written as the result of swapping the first two hypotheses, using $C$: $g = C h$, where
$$h: ¬¬(¬¬a → ¬b) → a → ¬b.$$
This can be arrived at as the composition $h = B k N$, of the double negative rule $N$ with $k$, where
$$k: (¬¬a → b) → a → ¬b.$$
This is just the converse double negative rule $ZN$ extended to the right: $k = CB(ZN)$. Thus
$$f = B g Z = B (C h) Z = B (C (B k N)) Z = B (C (B (C B (Z N)))) Z,$$
where
$$N = S (B Z V) I,\quad V = B Z K.$$
Running this in Combo, which I put up on GitHub not too long ago, as the expression
$$
V = B Z K,\quad N = S (B Z V) I,\quad k = C B (Z N),\quad h = B k N,\quad g = C h,\quad f = B g Z,\quad f$$
and turning on extensionality, the following is the result
$$\_0 = B Z,\quad \_1 = W (\_0 (\_0 K)),\quad B (C \_1) (B (Z \_1) Z).$$
That effectively calls out lemma $\_0$ for $B Z$, lemma $\_1$ for $W (\_0 (\_0 K))$ with the result being $B (C \_1) (B (Z \_1) Z)$.
This can be reduced to just $SKI$ form, if you wish, by making use of the following equivalences (proven using extensionality):
$$B x = S (K x),\quad C x y = S x (K y),\quad W x = S x I,\quad C x = B (S x) K = S (K (S x)) K.$$
Then we have
$$\_0 = S (K Z),\quad \_1 = S (\_0 (\_0 K)) I,\quad \_2 = S (K (S \_1)) K,\quad S (K \_2) (S (K (Z \_1)) Z).$$
The number of lines in a proof is $2n - 1$, where $n$ is the total number of $SKIZ$'s. The $SKIZ$-counts are: $3$ for $\_0$, $3 + 2×3 = 9$ for $\_1$, $4 + 9 = 13$ for $\_2$ and $6 + 9 + 13 = 28$ for the main result, for a total of $55$ lines.