<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def heightmap_add_voronoi( hm: np.ndarray, nbPoints: Any, nbCoef: int, coef: Sequence[float], rnd: Optional[tcod.random.Random] = None, ) -> None: """Add values from a Voronoi diagram to the heightmap. Args: hm (numpy.ndarray):
 A numpy.ndarray formatted for heightmap functions. nbPoints (Any):
 Number of Voronoi sites. nbCoef (int):
 The diagram value is calculated from the nbCoef closest sites. coef (Sequence[float]):
 The distance to each site is scaled by the corresponding coef. Closest site : coef[0], rnd (Optional[Random]):
 A Random instance, or None. """

    nbPoints = len(coef)
    ccoef = ffi.new("float[]", coef)
    lib.TCOD_heightmap_add_voronoi(
        _heightmap_cdata(hm),
        nbPoints,
        nbCoef,
        ccoef,
        rnd.random_c if rnd else ffi.NULL,
    )