fn legendre_symbol(element: &BigUint, modulus: &BigUint) -> BigUint {
        assert!(!element.is_zero(), "FpOp: Legendre symbol of zero called.");

        element.modpow(&((modulus - BigUint::one()) / BigUint::from(2u64)), modulus)
    }
Compute the Legendre symbol of a field element.

This indicates if the element is a quadratic in the prime field.

Ref: <https://en.wikipedia.org/wiki/Legendre_symbol>
crates/core/executor/src/hook.rs