.  It made the boy sad to see the old

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question
100%

In C++
oldmanSea.txt contains:
He was an old man who fished alone in a skiff in the Gulf of Mexico Stream and he had gone
eighty-four days now without taking a fish . 
In the first forty days a boy had been with him . But after forty days without a fish the boy’s 
parents had told him that the old man was now definitely and finally salao , which is the worst 
form of unlucky , and the boy had gone at their orders in another boat which caught three good fish the first week . 
It made the boy sad to see the old man come in each day with his skiff empty and he always went
down to help him carry either the coiled lines or the gaff and harpoon and the sail that was furled around the mast . 
The sail was patched with flour sacks and, furled , it looked like the flag of permanent defeat .
The old man was thin and gaunt with deep wrinkles in the back of his neck . 
The brown blotches of the benevolent skin cancer the sun brings from its reflection on the tropic sea were on his cheeks . 

Write a program that executes the following steps:
Reads the oldmanSea.txt and stores each word into a
set<string> container Novel
Reading SunHem.txt should use:
• getline(cin, WORD, '';
• where WORD is a string
Calculates the total number of unique words in this text
Calculates the number of characters in each unique word and
store this result I a histogram array, int Hist[20]
Hist[0] - contains the number of words having one
character
• Hist[1] - contains the number of words having two
characters
Hist[6] = contains the number of words having seven
characters
etc, etc ...
Print Histogram results
Calculates the number of words that start with an upper case letter
(numerical value of first letter < 92 && letter > 64 ) - Prints result
Transcribed Image Text:Write a program that executes the following steps: Reads the oldmanSea.txt and stores each word into a set<string> container Novel Reading SunHem.txt should use: • getline(cin, WORD, ''; • where WORD is a string Calculates the total number of unique words in this text Calculates the number of characters in each unique word and store this result I a histogram array, int Hist[20] Hist[0] - contains the number of words having one character • Hist[1] - contains the number of words having two characters Hist[6] = contains the number of words having seven characters etc, etc ... Print Histogram results Calculates the number of words that start with an upper case letter (numerical value of first letter < 92 && letter > 64 ) - Prints result
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 4 steps with 2 images

Blurred answer
Knowledge Booster
Perception
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education