You can use an IDE(http://en.wikipedia.org/wiki/Integrated_development_environment) which provides code management, highlighting, debugging facilities. You may try any of these.
QTCreator(http://qt-project.org/wiki/Category:Tools::QtCreator)
KDevelop(http://www.kdevelop.org/)
Eclipse(http://www.eclipse.org/)
or you may choose to use gdb(https://www.gnu.org/software/gdb/) directly from the command line.