Solved

program

Posted on 1997-03-07
2
201 Views
Last Modified: 2010-04-16
Hello,
         I have tried enough working with the problem written down. Please, provide me with every possible solution as soon as possible.

* Write a program to input a sentence, count the number of words, frequency of each vowel and the number of consonants, Display the results.
                        Thank you
0
Comment
Question by:hileen
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 

Accepted Solution

by:
yeast earned 200 total points
ID: 1215238
use an array to store characters as a word

while not eoln do
begin
   read(x);
   array[counter].character:=x;
end;

-Ethan
 
0
 

Expert Comment

by:nick030897
ID: 1215239
1.use a loop and obtain the number of spaces present in the sentense. That's a way to obtain the number of words used.
2. use separate counters for each vowel and increase them when the next char read is the same. (vowel frequency)
3. every other char different than vowel, space or digit should be treated as a consonant.So use anohter counter and take advantage of isaplha isdigit etc. functions.

Nikolay
0

Featured Post

Enroll in July's Course of the Month

July's Course of the Month is now available! Enroll to learn HTML5 and prepare for certification. It's free for Premium Members, Team Accounts, and Qualified Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes how to import Lotus Notes Contacts into Outlook 2016, 2013, 2010 and 2007 etc. with a few manual steps. You can easily export and migrate Lotus Notes contacts into Microsoft Outlook without having to use any third party tools.
This article outlines the struggles that Macs encounter in Windows-dominated workplace environments – and what Mac users can do to improve their network connectivity and remain productive.
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…

635 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question