I want to add a list of 3500 Strings from a text file folder into an array. I want a solution without using an ArrayList. This is what I have so far; I am trying to sort these Strings later on using a different class:
public static void main(String[] args) throws FileNotFoundException
{
File fileText = new File("wordlist.txt");
Scanner scan = new Scanner (fileText);
String[] word = new String[3271];
Comparator<String> com = new ComImpl();
Arrays.parallelSort(words, com);
for(String i: words)
{
System.out.println(i);
}
}