Whay would you want to go through the hassle of writing a program to solve to solve a quadratic equation`The calculator has two buit-in command to do just that. It has Solve and cSolve (for complex solutions).
Open a calculator sheet, and on the command line, type in
solve(ax^2+bx+c=0, x), press ENTER and wait for the solutions
×