Answer:Consider the following code segment:
void main()
{
string s1("example");
string s2("2468");
s1.insert(2,s2);
s1.erase(3,5);
s1.replace(2,3,s2);
cout<<s1;
cout<<endl;
}
What will be the output of the above code?
Options
a) ex2468ample
b) ex2ple
c) ex2468e
d) None of the above
Answer : c) ex2468e