Example of Observer pattern
This program allow to approximate a shape to draw it, using many points.
We want to make two changes:
if debugMode is enable.
-
Allow to main program to know the percentage of generated points inside the sphere.
-
Allow to main program to know the global percentage of generated points inside one shape.
-
The DrawShpere and AcceptShape cannot be changed.