try this out...
#include
#include
float valcal(float);
int main(){
float a,b,f,x,f1,f2,f3,i;
a=2;
b=3;
int flag=0;
f1=valcal(a);
f2=valcal(b);
printf("\n\n%f %f",f1,f2);
for(i=0;i<6;i++){
if(f1*f2<0){
x=a-((b-a)*f1/(f2-f1));
flag=1;
//printf("\n\nval of x : %f",x);
}
f3=valcal(x);
//printf("\n\nf3: %f",f3);
//(f3<0)?(f1=f3):(f2=f3);
if(f3<0){
f1=f3;
a=x;
}
else{
f2=f3;
b=x;
}
}
if(flag==1)
printf("\n\nTHE SOL IS : %f",x);
else
printf("\nNO SOLUTION\n");
printf("\n\n");
system("pause");
}
float valcal(float x){
float f;
f=((x*x*x)-(2*x)-5);
return f;
}
NEED MORE HELP...
CONTACT ME THROUGH MAIL...
yes
C- Programing is basically a programing language of a computer. It helps to create software programing language which is usefull in creating softwares & data base programes. C programing language is the first & basic programing language. Other programing languages are:- C, C++ & C# (latest).
c is a programing language
One of the statements, obviously.
c, c++, java, prolog, fortran, basic, ...
Using IDE environment
The most well-known programming languages are C, C++, C#, CSS, HTML, Javascript, PHP, Pascal/Delphi, Prolog, Python, Ruby, Visual Basic, and Visual Basic .NET, java.
C language is not a program, and it isn't an object-oriented language either.
C is descendent from another programing language called B which was at that time when 'C' was invented. That's why it derived its name as 'C' successive to 'B'.
C is a programming language. Example of C or C++ Programing would be the following: add matrices, get ip address, and read files.
* Java * C, C++ * Basic * COBOL * Fortran * Pascal * .Net * Visual Basic * etc...
we are using c plus plus programming for developing object oriented programing software.