Implemented the singleton design pattern to the covid19.py class. As we can use the same instance of the covid19 object to perform all data lookup it makes sense to restrict this class to only have 1 instance as the global access point. This pattern was applied by creating a new static method to provide access to the object and the constructor was modified to check if another instance exists and if it does to raise an exception. This way only one instance of the object is in memory at any time.
Implemented the singleton design pattern to the covid19.py class. As we can use the same instance of the covid19 object to perform all data lookup it makes sense to restrict this class to only have 1 instance as the global access point. This pattern was applied by creating a new static method to provide access to the object and the constructor was modified to check if another instance exists and if it does to raise an exception. This way only one instance of the object is in memory at any time.