Last edited on
you forgot to post your code and ask a question.

a hint that will make your job much more simple.
int responses[11] = {0};
for(all the file)

Last edited on
Last edited on
it would use the above idea to gather the data.
read the file into the buckets above.

most and least favorable response is just right there, for 0-10 find the highest value in bucket, for 0-10 find the lowest bucket (can do in same loop!).

print the historgram ... a simple sideways one is a double loop... for all the buckets, for the number in the buckets (say/5.0 since you have ? 50 people) print *.

frequency... common english or engineering statistics type question? I can't remember the equation... but google knows it, find it and wrap it up.

the whole thing is like 50 lines of code including comments and function headers and variables and the whole 9 yards.

Start simple. read the file into the hint design I gave you, and then do iii (the most and least common answers). Show us a solid real attempt at that.
how about someone post the format on how to do it
We prefer not to do peoples' homework for them. Its boring, usually, and they keep coming back for more if you do it, and they don't learn anything and graduate and get hired and then we have to do their work for them too, it never really ends. The only way to break the cycle is to offer help once effort has been given. Honestly I all but coded this one, though. There isnt much left but syntax.
notoriousboxing wrote:
how about someone post the format on how to do it

#include <iostream>
#include <cctype>
#include <limits>

int main()
   std::cout << "Do you want someone to do all the work for you? ";
   char answer{};
   std::cin >> answer;

   std::cin.ignore(std::numeric_limits<std::streamsize>::max(), '\n');

   if (std::toupper(answer) == 'Y' ) { std::cout << "Post it in the Jobs section.\n"; }

   else { std::cout << "Show what you have coded so far.\n"; }

   std::cout << "Good luck.\n";

Hint: if I do all the work for you, I am not cheap.
Last edited on
And what exactly is the problem? You edited your original post into gibberish.
And PLEASE learn to use code tags, they make reading and commenting on your code MUCH easier. It helps us to be able to help you.

Hint, you can edit your post and add them.
Another "I demand you do my homework for me for free" poster rage quits.

Oh, well. *sigh*
Registered users can post here. Sign in or register to post.