ddanbe is being nice. We don't do your homework for you - please read this site's terms of service. Make an honest attempt to solve the problem. Write the code. Post the code and problems, error messages, etc here and then we can help you.
I agree with rubberman, you should attempt to do the work yourself but to set you in motion look at rproffitt's article as well as write it out on paper. It is always good to trying to solve the program using Pseudo code and then do the actually programming. Ask yourself questions like, what is the square root as an exponent, can I express it as such or is there some sort of method or function provided for me for square roots? Depending on the programming language you are using go check out some different Math library's and explore functions they can provide you with. If they are built in look up documentation for squareroots online and try and use them that way. Ddbanbe provided you with a method for acquiring the difference between b^2 and 4ac all you have to do is figure out how to take the square root of that result.
You will also have to learn how to include different libraries so consider looking through your C book if you have one or online for information on that. That library and document have everything you need and it is up to you to figure out how to use them. It is important to learn how to read the documentation of online articles for library syntax as you will undoubtably need to read them on your journey into learning the language.