string replace java
public static void main(String args[]){
String s1="my name is khan my name is java";
String replaceString=s1.replace("is","was");//replaces all occurrences of "is" to "was"
System.out.println(replaceString);
}}
Also in Java:
- android how to know when snackbar is done
- java arraylist to array
- java int
- java find duplicates in array
- java collapse string array
- creating thread in java example
- how to open a text file in java
- leap year program in java
- java string to uuid
- java map declaration
- spigot respawn player location
- java loop through array
- binary string to int java
- how to remove a certain string in a arraylist java
- java insert element at position
- java get folder content
- how to create a linked list in java
- enum with numbers java
- Java array multidimensional hashcode
- java how to program
- count word in string no matter the delimiter java
- check if optional is empty java
- hashmaps java
- Write a JAVA method that expands a given binomial (ax + by)n, where integers a, b, n are user inputs. For example, if a = 2, b = -12, n = 4 are entered the method should print or return