You probably mean to use the equality operator (==) instead of the assignment operator (=).
cout<<"modecnt = "<<modecnt<<endl;
Since you didn't provide us with the input you're entering...
Type: Posts; User: Matticus
You probably mean to use the equality operator (==) instead of the assignment operator (=).
cout<<"modecnt = "<<modecnt<<endl;
Since you didn't provide us with the input you're entering...
This probably isn't immediately related to the problem you're seeing, but look at line 38 really carefully.