idocas.blogg.se

Notepad++ sort lines lexicographically
Notepad++ sort lines lexicographically








notepad++ sort lines lexicographically

String studentDetail = currentLine.split(” “) For each student record, create one Student object and add that Student object into studentRecords. Step 6 : Read every student record from input text file. Step 5 : Create an ArrayList to hold the Student objects.ĪrrayList studentRecords = new ArrayList() Step 4 : Create BufferedReader object to read the input text file.īufferedReader reader = new BufferedReader(new FileReader(“Pass The File Location Here”)) Writer = new BufferedWriter(new FileWriter("C:\\output.txt")) Creating BufferedWriter object to write into output file Reading all the lines of input file one by one and adding them into ArrayList Reader = new BufferedReader(new FileReader("C:\\input.txt")) Creating BufferedReader object to read the input file Create an ArrayList object to hold the lines of input file










Notepad++ sort lines lexicographically