hi all ,
i have a problem when i sort a vector of pairs
vector<pair<double,string> > v;
//consider the vector contains the following
//{ 0.625 , 0.5 , 0.5714 , 0.5714 , 0.6 , 0.4 }
//{"BEARS","GIANTS","COWBOYS","BRONCOS","DOLPHINS","LIONS"}
sort(v.begin(),v.end());
reverse(v.begin(),v.end());
//the expected list of strings should be : {"BEARS", "DOLPHINS", "BRONCOS", "COWBOYS", "GIANTS", "LIONS" }
//but i get {"BEARS", "DOLPHINS", "COWBOYS" ,"BRONCOS", "GIANTS", "LIONS" }
so, i really need help to figure out where is the bug 