Answer
$h = \frac{2gv^2}{a^2}$
Work Step by Step
Since $v$ and $a$ are in opposite directions, we can write an expression for the horizontal position $x$ as follows:
$x = v~t - \frac{1}{2}at^2$
Since the firecracker lands directly below the student, we can let $x = 0$.
$x = v~t - \frac{1}{2}at^2 = 0$
$t = \frac{2v}{a}$
We can find an expression for the height $h$.
$h = \frac{1}{2}gt^2$
$h = (\frac{g}{2})(\frac{2v}{a})^2$
$h = (\frac{g}{2})(\frac{4v^2}{a^2})$
$h = \frac{2gv^2}{a^2}$