C++ Program: Write a Program to Read Paragraphs

  • Context: Comp Sci 
  • Thread starter Thread starter abedhamayl
  • Start date Start date
  • Tags Tags
    C++
Join the discussion
Registration is free. Ask a follow-up in this thread, or start your own.
4 replies · 2K views
abedhamayl
Messages
4
Reaction score
0
Write a program that reads a paragraph of 4 lines of text. The user can enter extra spaces between words. The length of each line does not exceed 50 characters. The program should output the following: ((Use pointers))

1. A table indicating the occurrence of each letter of the alphabet in the text.
2. The input paragraph without extra spaces between words.
3. Average word length in the paragraph.
4. The list of words in the paragraph sorted in alphabetical order.
5. The 4 lines in the paragraph sorted in ascending order of length.


please help me
 
Physics news on Phys.org
Please post homework questions in the appropriate homework forums. (I have moved this thread there)

And please review our homework policy -- we will not do your work for you! You must indicate what work you've done, and what thoughts and analyses you've done on the problem -- if you don't show us that you've worked on the problem, then we won't work on the problem either.
 
just i want to
char *n[40][50];
cin>>*n;
how i can enter the names in this array and stop will i enter the new line
 
i use a
visual stdio 6.0