is computed by generating random points within a square, whose dimensions are 2 x 2, and checking how many of these points end up within a circle of radius 1. The ratio of that number to the total number of points generated by the random number server should be close to for a sufficiently large number of points.
The program begins by asking the user for required accuracy. The computation of will go on until either the required accuracy is reached, or until the number of points generated by the random number server exceeds certain hardwired limit.
The process responsible for writing to the VDU updates the displayed value of every time the results are collected from the workers.