Debugging with gdb
gdb is intended for C, C+ and FORTRAN programs. To use gdb effectively, you should compile all programs using the " g" option, to include program symbolic names in the compiler output. When this is done, gdb will be able to list lines in your source program, find the start of each procedure or method in your program, and find and print program variables. gdb will also know the declared type of each variable, and can print the variables in a useful format, based on this knowledge.