def METHOD_NAME(a, n):
    f = lambda j, i: reduce(mul, ((a[i] - a[k] if k != i else 1) for k in range(0, n - 1)), 1)
    F = np.fromfunction(np.vectorize(f), (1, n - 1), dtype=int)
    F = np.diagflat(F)
    F = np.append(F, np.zeros((n - 1, 1), dtype=int), axis=1)
    f = lambda i, j: (1 if j == (n - 1) else 0)
    z = np.fromfunction(np.vectorize(f), (1, n), dtype=int)
    return np.append(F, z, axis=0)