Results 1 to 5 of 5
- 03-21-2012, 02:21 AM #1
Member
- Join Date
- Mar 2012
- Posts
- 1
- Rep Power
- 0
New to Java and need help! Please!
I have an assignment that I am completely blown away by...if anyone could help guide me along it would be much appreciated.
Implement a class QuadraticEquation whose constructor receives the coefficients a, b, c of the quadratic equation ax2 + bx +c = 0. Supply methods getSolution1 and getSolution2 that get the solutions, using the quadratic formula. Write a test class QuadraticEquationTester that constructs a QuadraticEquation object, and prints the two solutions.
- 03-21-2012, 03:37 AM #2
- Join Date
- Jan 2011
- Location
- Richmond, Virginia
- Posts
- 3,069
- Blog Entries
- 3
- Rep Power
- 7
Re: New to Java and need help! Please!
The quadratic equation is (-b +- sqrt(b^2 - 4ac)) / 2a. From here it should be simple.
- 03-21-2012, 04:32 AM #3
- 03-21-2012, 11:21 PM #4
- Join Date
- Jan 2011
- Location
- Richmond, Virginia
- Posts
- 3,069
- Blog Entries
- 3
- Rep Power
- 7
Re: New to Java and need help! Please!
- 03-21-2012, 11:40 PM #5


LinkBack URL
About LinkBacks
Reply With Quote
.gif)

Bookmarks