Monte Carlo Method, Python, Numerical Integration, Data Science.
computed for random picked x_i. This is illustrated in figure 2 below. figure 2 By adding up the area of the rectangles and averaging the sum, the resulting number gets closer and closer to the actual result of the integral. In fact, the rectangles which are too large compensate for the rectangles