Question
Write and run a C program that reads numbers from an array and graphs these numbers in the form of a bar chart or Histogram.
Write and run a C program that reads numbers from an array and graphs these numbers in the form of a bar chart or Histogram. The program performs the following:
o Creates one array named Value of 10 elements.
o Define and implement a function named FillArray that receives two parameters: an array a of integers and its size n. FillArray Fills the array Value with random numbers in the range 1 to 20. Take into account to randomize the generated random values for each execution of the program.
o Define and implement a function named printArray that receives two parameters: an array a of integers and its size n. printArray Prints each number in the value array, then prints a bar consisting of that many asterisks (*) beside the number.
********** *** The output should be as follow: Sample Output Element Value Histogram 0 10 1 3 2 15 3 7 4 11 5 9 6 13 7 5 8 17 9 1Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started