This program is the first task of ISP RAS course C/C++ by I. R. Dedinsky
- Main project
- src/
- solver_quadratic_equation.c
- equation_lib.c
- src/
- Test project
- tests/
- tests_from_file.c
- tests.c
- test_lib.h
- tests/
- File with tests
- file_test.txt
To run main program
cmake .
make
./quadratic_equation
To run tests
cmake .
make
./tests
To run tests with data from .txt
- The line of test.txt looks like
a b c roots x1 x2
- roots = -42 means overflow, roots = -1 means infinite number of roots (value of x1 and x2 do not matter), if roots = 0 then x1 = -1 x2 = -1
- example
-1 -2 15 2 3.0 -5.0
or1.79769e+308 1.79769e+308 1.79769e+308 -42 0.0 0.0
- example for liner
0 1 0 1 0 0
or0 3 -9 1 3 0
cmake .
make
./tests_from_file
or To run tests from test_lib.h
cmake .
make
./tests
You can watch documentation by opening
docs/html/index.html
in browser.
KUbuntu 18.04