I have
int function(string n){
vector<int> n;
}
I want to call functions using the vector n, but..for some reason it keeps calling the string n functions..I thought it would call the closest dat
int function(string n){
{
vector<int> n;
n.size(); //vector!
}
n.size(); //string!
}
Although really, just rename the variable. Don't ever have variables with the same name in the same scope. Ever. People will hate you, and then there's all those nasty surprises in the afterlife.
精彩评论