#include
#include
using namespace std;
int main() {
float a,b,c;
cin>>a>>b>>c;
float d = b*b-4*a*c;
float d1 = sqrt(b*b-4*a*c);
int x = (-b +d1)/(2*a);
int y = (-b - d1)/(2*a);
if(d>0){
cout<<"the roots are real and distinct"<<endl;
if(x<y){
cout<<x<<" "<<y;
}
if(y<x){
cout<<y<<" "<<x;
}
}
if(d==0){
cout<<"the roots are real and equal"<<endl;
cout<<x<<" "<<y;
}
if(d<0){
cout<<"the roots are imaginary";
}
return 0;
}

