Search
 
SCRIPT & CODE EXAMPLE
 

JAVA

how to modify string in java

// Simply, create a new string with character replaced, because strings are immutable in java

String myName = "domanokz";
String newName = myName.substring(0,4)+'x'+myName.substring(5);
Comment

PREVIOUS NEXT
Code Example
Java :: compare two times in java 
Java :: discord jda 
Java :: java read next line 
Java :: clone array in java 
Java :: copy constructor in java 
Java :: android studio alert dialog box 
Java :: java array loop 
Java :: android separator line in view 
Java :: unique elements in array java 
Java :: fill two dimensional array columns by columns java 
Java :: creating a 2d arraylist in java 
Java :: java calendar add minutes 
Java :: 64 bit integer java 
Java :: default argument in java 
Java :: get thumbnail from video in android 
Java :: matrice java 
Java :: javafx textarea size 
Java :: boucles java 
Java :: java generate uuid 
Java :: how to change actionbar color in android programmatically 
Java :: how to delete character in string java 
Java :: java 2d array length 
Java :: setupactionbarwithnavcontroller problem 
Java :: Java How to use SortedSet? 
Java :: java append a string to file 
Java :: gat environment variables java 
Java :: java vector push_back 
Java :: check if a list contains a string java 
Java :: cardview implementation 
Java :: java substring based on delimiter 
ADD CONTENT
Topic
Content
Source link
Name
8+7 =