cout << "display all chores in sorted order\n\n" ;
for ( index = 0 ; index <= 2 ; index = index + 1 )
{
cout << childFirstName[ index ] << " choir amount" << choreType[ index ] << "\n" ;
cout << childFirstName[ index ] << " minutes labored " << choreMinutes[index] << "\n" ;
}
cout << "\n" ;
return 0;
}
Why do I keep getting undeclared indentifier?
These are the errors I keep getting:
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(41) : error C2065: 'totalMonthlyAllowance' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(43) : error C2065: 'totalChoreMinutes' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(55) : error C2065: 'totalMonthlyAllowance' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(57) : error C2065: 'totalChoreMinutes' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(59) : error C2065: 'childFirstName' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(66) : error C2065: 'totalMonthlyAllowance' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(66) : error C2065: 'totalChoreMinutes' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(67) : error C2065: 'averageChoreMinutes' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(67) : error C2065: 'totalChoreMinutes' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(70) : error C2065: 'averageChoreMinutes' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(84) : error C2065: 'childFirstName' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(85) : error C2065: 'childFirstName' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(103) : error C2065: 'childFirstName' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(104) : error C2065: 'childFirstName' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(120) : error C2181: illegal else without matching if
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(133) : error C2065: 'childFirstName' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(134) : error C2065: 'childFirstName' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(134) : error C2065: 'childFirstName' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(135) : error C2065: 'childFirstName' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(149) : error C2065: 'childFirstName' : undeclared identifier
1>c:\users\documents\c++\function not good\function not good\function not good.cpp(150) : error C2065: 'childFirstName' : undeclared identifier
Only people with to much time will take your code, put it on their computer and try to compile it and so on.
Please tell what you wonna reach und which errors or false results you get with this code.
Also write the code into source code tags with indents. So it's much easier for us to read and to understand.
Yeah Sorry, I accidently sent it before I put the errors in. Thank you for your comments last night that you left on my program, it helped me to understand a great deal!
Well they're all telling you that the variable you are referencing is not declared. In some cases you have
variable names misspelled, in some cases you have capitalization mismatches, and in other cases no
variable with a name close to the one you are trying to use has been declared.