rendered paste body#include "mapproc.h"
#include <iostream>
void main()
{
map<int,string> mapAll;
map<int,string>::iterator itr = mapAll.begin();
map<string,int> mapStaff;
map<string,int> mapStudents;
ReadInputFile(mapAll, "NameList.txt");
OutputNumerically(mapAll, "IdList.txt");
SplitIntoStaffAndStudents(mapStaff,mapStudents,mapAll);
OutputAlphabetically(mapAll, "AlphabeticList.txt");
// do the rest of the stuff
}
////////////////////////////////////////////////////////////////////////////
d:\documents and settings\administrator\my documents\uni\c++\assignment2\q3\map\mapmain.cpp(14) : error C2664: 'SplitIntoStaffAndStudents' : cannot convert parameter 1 from 'class std::map<class std::basic_string<char,struct std::char_traits<char>,c
lass std::allocator<char> >,int,struct std::less<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > >,class std::allocator<int> >' to 'class std::map<int,class std::basic_string<char,struct std::char_traits<char>
,class std::allocator<char> >,struct std::less<int>,class std::allocator<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > > &'
A reference that is not to 'const' cannot be bound to a non-lvalue