main()
{
clrscr();
}
clrscr();

Answers were Sorted based on User's Feedback



main() { clrscr(); } clrscr(); ..

Answer / surenda pal singh chouhan

No output/error

Explanation:
The first clrscr() occurs inside a function. So it becomes
a function call. In the second clrscr(); is a function
declaration (because it is not inside any function).

Is This Answer Correct ?    17 Yes 0 No

main() { clrscr(); } clrscr(); ..

Answer / revathi

the clrscr()inside the main() just clears the screen.
where the clrscr() outside the main() won't do any action.
it just act as a declaration.

Is This Answer Correct ?    8 Yes 3 No

main() { clrscr(); } clrscr(); ..

Answer / arpita

lines compiled- 4
warnings-1
errors-1

Is This Answer Correct ?    2 Yes 2 No

main() { clrscr(); } clrscr(); ..

Answer / skjha

One error.

Type mismatch occur.

Is This Answer Correct ?    1 Yes 1 No

main() { clrscr(); } clrscr(); ..

Answer / ishrat ali

type mismatch occur

Is This Answer Correct ?    0 Yes 0 No

main() { clrscr(); } clrscr(); ..

Answer / shruti

Gud question.. have to try this out..

m not sure about the answer..

because clrscr() is an inbuilt function.
so the clrscr() in the main will jump to the function body
which is defined in the header files..

for the second clrscr()...
i donno...

have to check it out.. :-(

Is This Answer Correct ?    1 Yes 4 No

Post New Answer

More C Interview Questions

What is scope rule of function in c?

0 Answers  


What will happen when freeing memory twice

2 Answers  


write a program to display the numbers in the following format 4 4 3 3 3 3 2 2 2 2 2 2 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 2 2 2 2 2 3 3 3 4

9 Answers   IBM, NIIT, Winit,


what is the difference between #include<stdio.h> and #include "stdio.h" ?

3 Answers  


if (i = 0)printf ("True"); elseprintf("False"); Under what conditions will the above print out the string "True" a) Never b) Always c) When the value of i is 0 d) all of the above

0 Answers  






4.weight conversion: Write a program that will read weight in pounds and convert it into grams.print both the original weight and the converted value.There are 454 grams in a pound.design and carry out a test plan for this program.

1 Answers   Wipro,


Why c is a procedural language?

0 Answers  


How can I call system when parameters (filenames, etc.) Of the executed command arent known until run time?

0 Answers  


How would you obtain the current time and difference between two times?

0 Answers   TISL,


What does 1f stand for?

0 Answers  


write the program to find multiplication of 2-D matrix??????????

1 Answers  


Which of the Following is not defined in string.h? A)strspn() B)strerror() C)memchr() D)strod()

2 Answers   Accenture, TCS,


Categories