(f, p, K)
return gf_strip(h)
Differentiate polynomial in ``GF(p)[x]``.

    Examples
    ========

    >>> from sympy.polys.domains import ZZ
    >>> from sympy.polys.galoistools import gf_diff

    >>> gf_diff([3, 2, 4], 5, ZZ)
    [1, 2]
Differentiate polynomial in ``GF(p)[x]``.
Differentiate polynomial in GF ( p ) [ x ] .
def gf_diff(f, p, K):
    """
    Differentiate polynomial in ``GF(p)[x]``.

    Examples
    ========

    >>> from sympy.polys.domains import ZZ
    >>> from sympy.polys.galoistools import gf_diff

    >>> gf_diff([3, 2, 4], 5, ZZ)
    [1, 2]

    """
    df = gf_degree(f)

    h, n = [K.zero]*df, df

    for coeff in f[:-1]:
        coeff *= K(n)
        coeff %= p

        if coeff:
            h[df - n] = coeff

        n -= 1

    return gf_strip(h)
def gf_diff ( f , p , K ) : df = gf_degree ( f ) h , n = [ K . zero ] * df , df for coeff in f [ : - 1 ] : coeff *= K ( n ) coeff %= p if coeff : h [ df - n ] = coeff n -= 1 return gf_strip ( h )