This is a nice one:
Code:
Clothing::Clothing() {
cout << "It is impossible to create a Clothing item, which isn't named anything" << endl;
}
We might not be interested in such an object at all. Let's use a trick:
Declare the default constructor
private. And don't implement it. so only:
Code:
class Clothing
{
public:
//...
private:
Clothing();
};
int main()
{
Clothing MyClothes; //illegal
}