  We study the number of meromorphic functions on a Riemann surface with given
critical values and prescribed multiplicities of critical points and values.
  When the Riemann surface is $\CP^1$ and the function is a polynomial, we give
an elementary way of finding this number.
  In the general case, we show that, as the multiplicities of critical points
tend to infinity, the asymptotic for the number of meromorphic functions is
given by the volume of some space of graphs glued from circles. We express this
volume as a matrix integral.
