def METHOD_NAME(filename, shape, typ, fortran_order):
    # generate random array
    arr = rng.random(shape) * 10.
    arr = arr.astype(typ)
    if fortran_order:
        arr = np.asfortranarray(arr)
    np.save(filename, arr)