I've been trying to figure out this error for a while and am totally blanking on what is going wrong. I keep getting a data member initialization error. Below are two separate chunks of code where the error is occurring.
1 2 3 4 5 6 7 8 9 10
class GA
{
private:
/* GA parameters */
double mutationRate = 0.015;
int tournamentSize = 5;
bool elitism = true;
public:
1 2 3 4 5 6 7 8 9
class Tour
{
private:
//holds our tour of cities
vector<City> tour;
double fitness=0;
double distance=0;
TourManager tourManager;
I feel I'm missing some basic principle of why you can't do this, but I've been racking my brain on this project for a week now and still can't figure out this error. If I can't initialize the values here where do I initialize them?