Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

can someone please show the code for this program and explain the reasoning with comments? thank you! C programming language please!! This assignment modifies your

can someone please show the code for this program and explain the reasoning with comments? thank you!image text in transcribedimage text in transcribed

C programming language please!!
This assignment modifies your quadratic formula plotter to be array-based. Retained from Before: Ask for input as you did before. You no longer need to solve for the roots of the quadratic, and you may remove those functions from your code. And Now, Something Different: You will still evaluate y ax2 + bx + cand print the results, for: 2 (0.0, 1.0, 2.0, 3.0, ...,10.0) x (1.0, 0.1, 0.01, 0.00000001) .E (1.0, 10.0, 100.0, 1 000 000 000.0) 2 (-10.0, -9.0, -8.0, ..., 8.0, 9.0, 10.0) . But now, there are additional caveats: O You must create arrays of all four of the above sets of values o You must use loops to initialize these arrays You must create arrays to store the y-results for all four of the above sets of values You still must have a single function that returns y= ax+ bx+c for a given a, b, C, and x; and use the loops to call it repeatedly You must also have a single function that: Accepts a, b, and c - Accepts an array of x values - Accepts a count of those x values - Accepts an array buffer for y values o Writes the computed y value for each x value into the corresponding spot in the y array buffer You must still format the printouts nicely, and make sure to distinguish between the four sets of values so the output is readable! 2 (0.0, 1.0, 2.0, 3.0,..., 10.0) x (1.0, 0.1, 0.01,. 0.00000001) X E (1.0, 10.0, 100.0,. 1 000 000 000.0) 2 (-10.0, -9.0,-8.0,..., 8.0, 9.0, 10.0) But now, there are additional caveats: You must create arrays of all four of the above sets of values You must use loops to initialize these arrays You must create arrays to store the y-results for all four of the above sets of values You still must have a single function that returns y = ax? + bx+c for a given a, b, c, and x; and use the loops to call it repeatedly You must also have a single function that: Accepts a, b, and c - Accepts an array of x values - Accepts a count of those x values - Accepts an array buffer for y values Writes the computed y value for each x value into the corresponding spot in the y array buffer You must still format the printouts nicely, and make sure to distinguish between the four sets of values so the output is readable! You must still go by the following: Do no arithmetic in main(). Create functions that do all your math. Do not use any global variables. Comment every function, every "paragraph" of code as we discussed in class, and any line of code that does more than two things. Indent your code properly. Your editor will do this for you! Let it. Your code must compile without errors (some warnings are okay at this stage - if you're concerned that a warning might not be okay, ask me) and run with any reasonable values of a, b and C - I'll be testing them on my end

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

Practical Oracle8I Building Efficient Databases

Authors: Jonathan Lewis

1st Edition

0201715848, 978-0201715842

More Books

Students also viewed these Databases questions

Question

Explain key approaches to implementing LMD

Answered: 1 week ago