Computer Science Problem with Quadratic Code!?

Breezy

New member
I cant figure out what goes in the parts where I put "______" , please help

/**
* Quadratic Equations. Checks numbers for solutions
*/

import java.io.*;
import java.util.Scanner;

public class QuadraticEquations

{
public static void main (String[] args)
{
int a = 0, _______________; //declare variables for coefficients in equation
double x1 = 0, ______________; //declare variables for discriminant and solutions

Scanner kboard = new Scanner(System.in);
System.out.println();
System.out.println("Enter the values of a, b, c for the ");
System.out.println("quadratic equation to be solved, one per line: ");

a = kboard.nextInt(); // get value of a
__________________;
____________________;

System.out.println("The equation " ____________ " = 0 has solutions of:");
// print out equation with a, b, and c in appropriate places

discr = ______________; //compute the discriminant
x1 = __________________; //___________________
____________________; // computer second solution

System.out.println("x1 = " _____________); // print first solution
__________; // print second solution
}
}
 
Back
Top