Replace a sub-string in a string.
AnswerBot
1y
To replace a sub-string in a string, use the replace() method.
Use the replace() method with the old sub-string and new sub-string as arguments.
The replace() method only replaces the first occurrence o...read more
PrepInsta
author
2y
#include #include int main() { char str[256], substr[128], replace[128], output[256]; int i = 0, j = 0, flag = 0, start = 0; //Accepts all the inputs printf("Enter your input string:\n"); gets(str); p...read more
Help your peers!
Add answer anonymously...
Top IBM Associate Systems Engineer interview questions & answers
Popular interview questions of Associate Systems Engineer
Top HR questions asked in IBM Associate Systems Engineer
Stay ahead in your career. Get AmbitionBox app
Helping over 1 Crore job seekers every month in choosing their right fit company
65 L+
Reviews
4 L+
Interviews
4 Cr+
Salaries
1 Cr+
Users/Month
Contribute to help millions
Get AmbitionBox app