Complete the code in Appendix C to take the parameter as input from the keyboard and solve the equation