Question: Write a program that reads a string of up to 9 lower-case letters from the standard input and prints out the longest words (in words.txt)
Write a program that reads a string of up to 9 lower-case letters from the standard input and prints out the longest words (in words.txt) that can be formed by reordering the letters. Each input letter can be used at most once to form the out-put word. If there is more than one word of the maximum length, print out all of them in alphabetical order, each on a new line. Name your program LongestWords. For example, if the input is njwhoaurgthen the correct output is jargon ourang
In java
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
