in the midst of those words he was trying to say, in the midst of his laughter and glee, he had softly and suddenly vanished away, for the snark was a boojum, you see.the output would be,
Word Line Numbers ------------ ----- a 4 and 2, 3 away 3 boojum 4 for 4 glee 2 had 3 he 1, 3 ... ...Additional requirements:
Your design should show a thorough decomposition of the problem. Be sure to encapsulate everything, even line numbers. (You shouldn't use int to represent line numbers, because line numbers can't be negative. So build a class for line numbers that doesn't allow them to be negative.) Perhaps this is a bit contrived, since you might not go to all that trouble in a real problem, but this is a design exercise, so show an exhaustive decomposition.
Draw a detailed UML class diagram of your solution, which includes all
attributes and complete method signatures.