Hi, @jyra,
You can go through this example:
String word = "THis is test programe &%^#%$";
String replaced = word.replace("work", "test");
System.out.println("Original String before replace : " + word);
System.out.println("Replaced String : " + replaced);