I am having difficulty with this. I do not understand how to writea program that
ID: 3614679 • Letter: I
Question
I am having difficulty with this. I do not understand how to writea program that solves polynomials and what I have is underneath thequestion. I know its not right but can someone help me with thisplease. (you will see I used: (pow) since that means powers and onthe sheet I have it says pow(x,y), but I do not think the way I didit is right). I use double for the x instead of float b/c he wantsus to use double. But can someone assist me please? ThanksQ: Write a function that computes the value of the followingpolynomial:
3x5 + 2x4 - 5x3 - x2+7x -6
Write a program that asks the userto enter a value for x, calls the function to compute the value ofthe
polynomial, and then displays thevalue returned by the function?
________________________________________________________________________________
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
int main (void)
{
int p,
double x;
printf ("Enter a value for x: ");
scanf ("%lf", &x);
p = pow(3,5) + pow(2,4) - pow(5,3) + pow(1,2) +pow(7,1) - 6;
printf ("The value of %lf is: ", p);
getch ();
return 0;
}