This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
Please incorporate Ulf’s suggestions in your code and post it anew.
Dan Rh Jones
Joined: Aug 16, 2011
(Haven't reproduced all of the code as it is for the Java ranch assignments)
produces the following error:
readFile(java.lang.String) in SortNames cannot be applied to (java.util.List)
for (Object string : readFile(blah))
Joined: Oct 13, 2005
The error about List suggests you might have your own List class.
Major error: why are all those methods static? That is non‑object‑oriented programming. You should have a class which has the List of names as a field, and it can sort its List, display contents, etc.