Answers for "how to save an arraylist to a text file in java and retrieve data from that file"

0

java text file to arraylist

Scanner s = new Scanner(new File("filepath"));
ArrayList<String> list = new ArrayList<String>();
while (s.hasNext()){
    list.add(s.next());
}
s.close();
Posted by: Guest on June-14-2020

Code answers related to "how to save an arraylist to a text file in java and retrieve data from that file"

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language