code: def kolmogni(n, q, cdf=True):
      """Computes the PPF(or ISF) for the two-sided Kolmogorov-Smirnov distribution.
  
      Parameters
      ----------
      n : integer, array_like
          the number of samples
      q : float, array_like
          Probabilities, float between 0 and 1
      cdf : bool, optional
          whether to compute the PPF(default=true) or the ISF.
  
      Returns
      -------
      ppf : ndarray
          PPF (or ISF if cdf is False) at the specified locations
  
      The return value has shape the result of numpy broadcasting n and x.
      """
      it = np.nditer([n, q, cdf, None])
      for _n, _q, _cdf, z in it:
          if np.isnan(_n):
              z[...] = _n
              continue
          if int(_n) != _n:
              raise ValueError(f"n is not integral: {_n}")
          _pcdf, _psf = (_q, 1 - _q) if _cdf else (1 - _q, _q)
          z[...] = _kolmogni(int(_n), _pcdf, _psf)
      result = it.operands[-1]
      return result
  
file_path: catboost/contrib/python/scipy/py3/scipy/stats/_ksstats.py
imports: import numpy
  import scipy.special
  import scipy.special._ufuncs
  import scipy.misc
label_desc: Use image node_id 13 for calling a global function with example usage: kolmogni(n, q, cdf) and returns: result