0

How can I solve a quadratic equations?

In C++

21st Sep 2018, 1:05 PM
Tom
Tom - avatar
2 Antworten
+ 1
#include <math.h> int main(){ double a = n double b = n double c = n double result = (b * -1) + sqrt(b * b - 4 * (a * c)) / 2 * a }
21st Sep 2018, 1:26 PM
Ramphy Aquino Nova
Ramphy Aquino Nova - avatar
+ 1
Ramphy Aquino Nova using #include <cmath> is better
21st Sep 2018, 1:41 PM
hinanawi
hinanawi - avatar