/* main.. //*/ int main() { using namespace std; Singleton* ptr = NULL; do{ cout << "create Singleton:\n"; if(NULL == (ptr = Singleton::getInstance())){ cout << "Singleton allocation failed!\n"; break; } cout << endl; cout << "use the Singleton\n"; ptr->doSomething(); cout << endl; cout << "destroy Singleton.. - is not permitted!\n"; }while(false); cout << "READY.\n"; return 0; }