1112131415161718192021
public static void main(String[] args) { Dictionary d; try { d = new Dawg(); d.fromFile(dictionaryPath); for (String s : wordToFind) System.out.println("The dictionary " + (d.contains(s) ? "contains" : "does not contain") + " the word " + s); }