<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def vdistg(v1, v2, ndim):
 """ Return the distance between two vectors of arbitrary dimension. http://naif.jpl.nasa.gov/pub/naif/toolkit_docs/C/cspice/vdistg_c.html :param v1: ndim-dimensional double precision vector. :type v1: list[ndim] :param v2: ndim-dimensional double precision vector. :type v2: list[ndim] :param ndim: Dimension of v1 and v2. :type ndim: int :return: the distance between v1 and v2 :rtype: float """

    v1 = stypes.toDoubleVector(v1)
    v2 = stypes.toDoubleVector(v2)
    ndim = ctypes.c_int(ndim)
    return libspice.vdistg_c(v1, v2, ndim)