answersLogoWhite

0


Best Answer

Hay buddy this is homework. U have to solve it by urself.

User Avatar

Wiki User

12y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Write the function replace which finds the string from in the string string and replaces it with the?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Write a function to reverse a string and to display it?

Yes.


How do you write string in reverse through the HTML tags?

Not possible through html. Use php strrev function. For eg:


Write a Program to convert decimal number into hexadecimal no without using function and string?

This is not a question.


Write a program to replace r by R in the string rose is a rose in c sharp?

string rose = "rose"; rose = rose.Replace('r', 'R');


Write a c program using string concept enter a sting and replace the new string in to old string and find no of occurrence?

print c co com comp compu


Write a program to concate the string without using strconcat function?

If you don't need to preserve the first string you could just iterate over the second string and copy each character onto the end of the first string, then return that


How do you write a program using function that counts the number of vowels in a string in java language?

Use text-editor notepad++


How do write a function that receives two pointers to character strings where the function concatenates the two strings and prints the new concatenated string?

#include <iostream> #include <string> std::string* concat_print_strings(std::string* pStr1, std::string* pStr2 ) { std::string * strResult = new std::string( *pStr1 ); strResult->append( *pStr2 ); std::cout << strResult->c_str() << std::endl; return( strResult ); } int main() { std::string str1 = "This is a string."; std::string str2 = " And this is another string."; std::string* pStr = concat_print_strings( &str1, &str2 ); delete( pStr ); pStr = NULL; return( 0 ); }


How do you write a function called mystrlen that receives a pointer to a character string so that the function return the length of the string?

int mystrlen (const char *s) { const char *t; if (!s) return 0; for (t=s-1;*++t;); return t-s; }


Using Python write an algorithm that takes a string as input and determines whether or not it is a palindrome?

def isPalindrome(s): return s == s[::-1] then just call the function with a string like isPalindrome('poop')


Write a program in c to convert a given string to lower case?

Use the tolower() function. Example: char* a = 'X'; a = tolower(a); printf("%c", a);


How do you write a algebraic expression for twice as long as the length of the string?

You can write 2X, where X is the length of the string.