1 l 2 Cereal Brands and Calories 120 calories - 100 calories- 110 calories- 130 caloies 60 calories 160 calories Froot Loops Apple Jacks Corn Pops Corn Flakes frosted flakes Cinamon Toast Fiber one wheat chex сосоа puffs Honey smacks Oreo O's frosted krispies lucky charms Rice Chex Cookie crisp Reeses Puffs Golden grahams Rice Krispies Special K Corn CHex Waffle Crisp 190 calories- 200 calories- 230 calories- Raison Bran shredded wheat Healthy heart Create A,c++ psudocode using the information given above with the calories and the cereal below it. The first text in the file is a header for the file. Each remaining item is a string of the cereal name and an int representing its calories. With the file reading read the data in, store header in a string variable and the rest of data into a map ( key should be cereal, value should be calories. Calculate the mean calories of all cereals and display the amount in joules 1 calorie = 4.184j. Print out the cereals that are less than the mean and greater than the mean. Also the 2 groups need to be in alphabetical order. Include notes and explanations please. Put in container(map,set,vector,etc). %3D

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

I need this in a C++ code please. Consider the information in the image.

2.
Cereal Brands and Calories
110 calories-
frosted flakes
сосоа puffs
Honey smacks Oreo O's
frosted krispies
lucky charms
130 caloies
Cinamon Toast
120 calories -
100 calories-
60 calories
Fiber one
160 calories
Corn Flakes
Rice Chex
Froot Loops
wheat chex
Apple Jacks
Corn Pops
Reeses Puffs
Golden grahams
Rice Krispies
Special K
Cookie crisp
Corn CHex
Waffle Crisp
190 calories-
200 calories-
230 calories-
Raison Bran
shredded wheat
Healthy heart
Create A,c++ psudocode using the information given above with the calories and the cereal
below it.
The first text in the file is a header for the file. Each remaining item is a string of the cereal name
and an int representing its calories.
With the file reading read the data in, store header in a string variable and the rest of data into a
map ( key should be cereal, value should be calories.
Calculate the mean calories of all cereals and display the amount in joules 1 calorie = 4.184j.
Print out the cereals that are less than the mean and greater than the mean. Also the 2 groups
need to be in alphabetical order. Include notes and explanations please. Put in
container(map,set,vector,etc).
Transcribed Image Text:2. Cereal Brands and Calories 110 calories- frosted flakes сосоа puffs Honey smacks Oreo O's frosted krispies lucky charms 130 caloies Cinamon Toast 120 calories - 100 calories- 60 calories Fiber one 160 calories Corn Flakes Rice Chex Froot Loops wheat chex Apple Jacks Corn Pops Reeses Puffs Golden grahams Rice Krispies Special K Cookie crisp Corn CHex Waffle Crisp 190 calories- 200 calories- 230 calories- Raison Bran shredded wheat Healthy heart Create A,c++ psudocode using the information given above with the calories and the cereal below it. The first text in the file is a header for the file. Each remaining item is a string of the cereal name and an int representing its calories. With the file reading read the data in, store header in a string variable and the rest of data into a map ( key should be cereal, value should be calories. Calculate the mean calories of all cereals and display the amount in joules 1 calorie = 4.184j. Print out the cereals that are less than the mean and greater than the mean. Also the 2 groups need to be in alphabetical order. Include notes and explanations please. Put in container(map,set,vector,etc).
Expert Solution
Step 1

They have supplied a list of calorie-containing foods in the problem statement. And we need to write the code for the required scenario and get the user input for the list of items as string and the calories as the integer datatype.

Algorithm:

1. Start.

2. Get the user input for the list of items and calories with their specific datatypes like items for items as string and for calories as integers.

3. Store all the required input details in the datatypes like list, dictionary or other any required data containers. 

4. Then we need to find the mean for all the required calories of the list like

                              Mean= (sum of all calories / number of calories)

 

arrow_forward

 

steps

Step by step

Solved in 3 steps

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY