I forgot about this since my compiler has extensions allowing it. The problem is a potential parse error caused by '>>'.C++03 will interpret >> as operator>>, not as the closing brackets of a template. To fix it, you have to include spaces.Code:vector<pairs<string, int>> pair;Code:vector<pairs<string, int> > pair;
If I did your homework for you, then you might pass your class without learning how to write a program like this. Then you might graduate and get your degree without learning how to write a program like this. You might become a professional programmer without knowing how to write a program like this. Someday you might work on a project with me without knowing how to write a program like this. Then I would have to do you serious bodily harm. - Jack Klein