66. A programmer tries to debug a code of 10,000 lines. It is known that there is a logical error in the first 25 lines of the code. Which of the following is an efficient way to debug the code ?
A. Compile and check line by line
B. Use interpreter on the first 25 lines of code
C. Compile and run the entire code
D. None of the above
(b)
67. The C Processors are specified with _______ symbol.
A. *
B. #
C. $
D. “
(b)
68. A variable declared in a function can be used in main ?
A. True
B. False
C. True if declared static
D. None of the above
(b)
69. Which is not a valid C statement :
A. int _t=0;
B. int Main=2;
C. float rate;
D. int $main;
(d)
70. What is the default return type if it is not specified in function definition ?
A. void
B. int
C. double
D. short int
(a)
Ans 70 will be int. Remember return 0. Here 0 is int
Dear Anish,
If a return value isn’t required, declare the function to have void return type. If a return type isn’t specified, the C compiler assumes a default return type of int. In a main function, the return statement and expression are optional.