#ifndef EXCEPTH #define EXCEPTH #include //for ostringstream #include //for exception #include using namespace std; class except: public exception { const string s; public: ~except() throw () {} except(const string& initial_s) throw () : s(initial_s) {} except(const ostringstream& ost) throw () : s(ost.str()) {} const char *what() const throw () {return s.c_str();} }; #endif