Hi there i need some help with this part one text area is fine and getting it from text to array,and sorting it in alphabetical order,but not sure how to remove duplicates,and also how you let it show how many times each word was used,and how do you clean up the text before you start the computation.
The whole problem follows:
Enable the user to submit a paragraph of text using a text area form element. Convert the
submitted text into an array of words. Provide the user with two neatly printed lists.
• The first list should show all the words in the paragraph in alphabetical order with
duplicates removed.
• The second list should show all the words in the paragraph with a corresponding
number indicating how many times the word was used in the paragraph. Sort the list
from the most to the least used words.
The whole problem follows:
Enable the user to submit a paragraph of text using a text area form element. Convert the
submitted text into an array of words. Provide the user with two neatly printed lists.
• The first list should show all the words in the paragraph in alphabetical order with
duplicates removed.
• The second list should show all the words in the paragraph with a corresponding
number indicating how many times the word was used in the paragraph. Sort the list
from the most to the least used words.