What problem are you trying to solve with this code? It appears as if you want to take a list of strings, then print out whether or not the each unique string is a palindrome.
>/* Counting duplicates */
This isn't entirely truthful. It looks more like you're removing duplicates and keeping a count of how many removals there were.
>If I start the main while block as while(wordListNextIterator != wordList.end()) there are no problems
Consider the cases where wordListNextIterator is equal to wordList.end() and you shouldn't have much trouble finding your problem. Also keep in mind the restrictions that are placed in wordList.end() (it's not a valid list item, just a sentinel, so you can't do to much with it).
Narue
Bad Cop
15,460 posts since Sep 2004
Reputation Points: 6,464
Solved Threads: 1,401