Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Help in C Language. Create and display a histogram using the values in a file 1) Prompt the user for a filename, if the file

Help in C Language.

Create and display a histogram using the values in a file 1) Prompt the user for a filename, if the file does not exist your code should output "could not open file" and then exit 2) Open that file and read the integers from the file (each integer will be between 0 and 9, inclusive), if a value that is not between 0 and 9 is encountered your code should output "incorrect value" and then exit 3) we want to count how many times each of the values between 0 and 9 appears in the file 4) then display the total number of values read from the file, and how many times each particular value was in the file

#include

int main() {

/* Type your code here. */

return 0; }

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Processing Fundamentals, Design, and Implementation

Authors: David M. Kroenke, David J. Auer

14th edition

133876705, 9781292107639, 1292107634, 978-0133876703

More Books

Students also viewed these Databases questions