#include "stdafx.h"
#include <stdio.h>
#include <math.h>
#include <iostream>
using namespace std;


int main()
{
int a; 
int b; 
int c;
double X1;
double X2;
double D;
 cout<<"a=";
 cin>>a>>endl;
cout<<"b=";
 cin>>b>>endl;
cout<<"c=";
 cin>>c>>endl;
   X1 = (-b+sqrt((b*b)-(4*a*c)))/(2(a));
   X2 = (-b-sqrt((b*b)-(4*a*c)))/(2(a));
    D =(b*b)-(4*a*c));
 if (D >= 0)

  { 
cout<<"..."<<X1<<X2<<endl;
 }  
    if (D < 0) {
        cout<<"no real roots to compute"<<endl;
    }

 return 0; 
}

It gives me that error : error C2064: term does not evaluate to a function taking 1 arguments.
What should I do?

which line?

cin>>c>>endl;

Line 21: endl can not be used cin, it's only useful for outpout streams, not input streams.

Thanks everything works now.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.