Hi,
I have faced a problem that I have a vector in my class which I would like to initialize using constructor initialization list with some thing like this std::vector<double>({1,4,5}) which is only allowed in c++11 which is not what I am looking for. I could only intialize it with one value 0 as shown in the code below. Is there is anyway I can do it without going to the constructor body?
Data::Data()
:V(std::vector<double>(3,0)),
/* Default Constructor */
{
}
thanks!