Open Project
Open Project
Introduction
Title: A calculator of quadratic equation
Description: This program this program gets the coefficient of quadratic equation and display the real
solution of the equation. It equally displays a message “No real roots” when there is not real solution to
the equation.
2.Design
Pseudo code
Variable:
- a, b, and c will be used as variable to do this program. Since we need a real solution then the variable
will be an integer.
Formula: Since we need the root the following formula will be use to find the two real roots of the
equation named alpha and beta.
−𝑏 + √𝑏 2 − 4𝑎𝑐
∝=
2𝑎
−𝑏 − √𝑏 2 − 4𝑎𝑐
𝛽=
2𝑎
The following test plan was prepared to test the final program and the algorithm was dry run with the
test plan data.
Steps
1. Coding
2. Compiling and correcting errors
Source Code
The syntax errors were corrected by checking the appropriate format and if any semicolon is omitted.
4.Testing
Strategy used: The output was compared with the initial design so that the result match the expected
value.
Outputs
5.Conclusion
The main difficulty was to compile and correct errors