Write your question here. I keep getting an expected primary-expression before ‘int’ error, and I cant really figure out why. I feel like it's something really obvious and cant notice, please help.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
army::army(string n):name(n)
13 {
14
15 add_cannon_fodder(int x);// where I get the error
16 }
17 int army::add_cannon_fodder(int x)
18 {
19 srand(time(NULL));
20
21 cout<<"Number of reinforcements"<<RAND_MAX<<endl;
22
23 for(int i = 0; i<10; i++){
24
25 cout<<RAND_MAX<<endl;
26 }
27 }