Write a recursive function to compute the Jacobi symbol J(a, n), is defined for relatively prime integers a and n, a> o, \mbox{ and } n > 0 by the formula
J(a, n) = 1 \mbox{ if a = 1, } = J(a/2, n)*(-1)^\frac{n^2-1}{8} \mbox{ if a is even, }
=J(n \% a, a)*(-1)^\frac{(a-1)*(n-1)}{4} \mbox{...