Monte Carlo implementation