#include <iostream>
#include <string>
using namespace std;
void chuli(string a)
{
a.erase(0,2);
}
int main()
{
string a = "012345";
a = chuli(a);
cout << a;
}
beginner for C++,i want to know why after this function,this string don't change.Is this something about the namespace?
Aucun commentaire:
Enregistrer un commentaire