import java.util.Scanner;
import java.lang.Math;
class Root1
{
int a;
int b;
int c;
double root1;
Root1(int x, int y, int z)
{
a=x;
b=y;
c=z;
}
public double calculateRoot1()
{
int d= b*b-(4*a*c);
root1=(-b+Math.sqrt(d))/2*a;
return root1;
}
}
class Root2
{
int a;
int b;
int c;
double root2;
Root2(int x, int y, int z)
{
a=x;
b=y;
c=z;
}
public double calculateRoot2()
{
int d= b*b-(4*a*c);
root2=(-b-Math.sqrt(d))/2*a;
return root2;
}
}
public class RootMain
{
public static void main(String args[])
{
Scanner input=new Scanner(System.in);
System.out.println("Enter value of a");
int a=input.nextInt();
System.out.println("Enter value of b");
int b=input.nextInt();
System.out.println("Enter value of c");
int c=input.nextInt();
Root1 r1= new Root1(a,b,c);
System.out.println("Value of Root 1 is:"r1.calculateRoot1());
Root2 r2=new Root2(a,b,c);
System.out.println("Value of Root 2 is:"r2.calculateRoot2());
}
}