PROGRAMMING:JMU Java & Python - count the number of words in a paragraph of text and sort them in alphabetical order
Now we need to count the number of different words in several paragraphs.
If the number of different words does not exceed 10, all the words will be output (in alphabetical order), otherwise the first 10 words will be output.
**Note 1: * * words are separated by spaces (one or more spaces).
**Note 2: * * ignore blank lines or blank lines.
**Note 3: * words are case sensitive, that is, 'word' and 'word' are two different words.
###Input description
Several lines of English, finally with '` For the end.
###Output description
Different number of words.
Then output the first 10 words (in alphabetical order), if all the words are no more than 10, then output all the words.
###Input sample
```in
Failure is probably the fortification in your pole
It is like a peek your wallet as the thief when you
are thinking how to spend several hard-won lepta
when you Are wondering whether new money it has laid
background Because of you, then at the heart of the
most lax alert and most low awareness and left it
godsend failed
!!!!!
```
###Output sample
```out
forty-nine
Are
Because
Failure
It
a
alert
and
are
as
at
```
answer:If there is no answer, please comment
If the number of different words does not exceed 10, all the words will be output (in alphabetical order), otherwise the first 10 words will be output.
**Note 1: * * words are separated by spaces (one or more spaces).
**Note 2: * * ignore blank lines or blank lines.
**Note 3: * words are case sensitive, that is, 'word' and 'word' are two different words.
###Input description
Several lines of English, finally with '` For the end.
###Output description
Different number of words.
Then output the first 10 words (in alphabetical order), if all the words are no more than 10, then output all the words.
###Input sample
```in
Failure is probably the fortification in your pole
It is like a peek your wallet as the thief when you
are thinking how to spend several hard-won lepta
when you Are wondering whether new money it has laid
background Because of you, then at the heart of the
most lax alert and most low awareness and left it
godsend failed
!!!!!
```
###Output sample
```out
forty-nine
Are
Because
Failure
It
a
alert
and
are
as
at
```
answer:If there is no answer, please comment