If I have an object in a program that shouldn't be duplicated, (it should only be created once), should the class that defines that object be "static"?
As an example: I have defined a LapCounter class to count the number of times a RaceCar object makes a lap around the track. I only need one LapCounter object. Should I simply define the LapCounter class as a static class?
Do you still have to use the "new" statement to create a instance of a static class to access it's member variables and methods?
As an Example: The LapCounter class defines a method named "UpdateNumberOfLaps". If LapCounter was a static class do I still have to create a LapCounter object before I can call LapCounter.UpdateNumberOfLaps from my RaceCar object?