You are here:

C/watch!!!!

Advertisement


Question
i am talkin about turbo c.in a c program i just want to watch the values of a variable during its execution.what shud i do?

Answer
I don't use any of these IDEs such as VC++ or Turbo C.
I alsways use gdb.

As far as I know, these IDEs provide everything at the click of a button.
I think, in the same drop down where you find the "Make", "Build", "Step In" etc commands, the "watch" also should be there.

Also, there must be another way to do this.
When the execution reaches a particular statement (where you want to watch the value of a variable), you can Right-Click on the variable name and select "watch" or Double-Click on the variable name and a watch window opens.

These are the things which you can try to get the watch window. Since, I don't have the Turbo-C compiler, I cannot give the exact answer.

Also, there is a help button to find out the usage and you can search for "watch" there.  

C

All Answers


Answers by Expert:


Ask Experts

Volunteer


Narendra

Expertise

I can answer questions in C related to programming, data structures, pointers and file manipulation. I use Solaris for doing C code and if you have questions related to C programming on Solaris, I will be able to help better.

Experience

6.5

Organizations belong to
Sun Microsystems

Awards and Honors
Brain Bench Certified Expert C programmer.
Advanced System Software Certified

©2012 About.com, a part of The New York Times Company. All rights reserved.