The following example shows how to create and handle objects of the class counter from the counter from the example in the section Classes.