create a class which contains 2 private members expressing the coefficients of a first grade equation with 1 variable, a function that returns the number of equation's roots (consider n/0 and 0/0),and a function that returns the equation's root if it does exist.
Please don't do that. Someone will get around to helping you out when they get around to it. Some other people might not have an answer for you. Be patient; this isn't a tutor service, we're not being paid to answer your questions.