class CBAY_ITEM
{
public:
string name = enterName();
string condition = enterCondition();
};
when I compile, it gives 4 errors, which say
1.a function call cannot appear in a constant-expression
2.ISO C++ forbids initialization of member 'name'
3.making 'name' static
4.invalid in-class initialization of static data member of non-integral type 'std::string'
what am I doing wrong here??