void change(char* input){
memset(input, 'a', strlen(input));
}
int main(){
char* p = "foo";
cout << p << endl;
change(p);
cout << p << endl;
}
Devon_4
0
Newbie Poster
deceptikon
1,790
Code Sniper
Team Colleague
Featured Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.