Published
- 1 min read
arraylist of characters
The solution for this is noted below
arraylist of characters
Solution
import java.util.ArrayList;
public class Test{
String words = new String("HELLO GOODBYE!");
ArrayList<Character> sample = new ArrayList<Character>();
for(int i = 0; i<words.length(); i++){
sample.add(words.charAt(i));
}
}
Try other methods by searching on the site. That is if this doesn’t work