Void main()
{
If(printf("C") && getch ())
}
Then output is C.
If I wrote clrscr() in the place of getch() then it gives error message why..

Answer Posted / shresth tyagi

in if statement if you are using && then it will give you output when both the conditions are true , if one of the conditions are not true than the compiler will give you an error and the correct program is ;
void main()
{ clrscr(); // it is used to clear anything on the command prompt
int i=1;
if(i==1)
printf("C");
getch(); // it is used to get character or string to print
}

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is the significance of transistor number (exam. BC557,CIL188 etc) ?

2180


What do you mean by traffic profile?

2780


What is the advantage of using ayrton or universal shunt in multi-range ammeters?

1083


Why is transistor called a current controlled device ?

801


Do you know q-meter works on which principal?

740


Explain capacitance?

790


Explain what is the difference allen bradley and siemens plc

795


What is cache coherency and snooping

786


types of communication scheme in power plant ?

2329


Suppose in market 4n27 is not easily available so which opto isolator can I use at the place of this? What is 4n27

768


draw the fig of bridge rectifier?

1891


69,70 or 71 in box-1 ; 18,19, or 20 in box-2 ; 60,61, or 62 in box-3 get -3 , -4 , or -5 in box-2 in 3 steps.Use all operations i.e. ( +,-,*,/ ).

2106


what is limitation of auto transformer?

1968


hi sir i completed my b tech in ece in 2009 and i am interested in railway jobs and plz provide me with what type of questions will they ask along with model paper and my mail id is vaseem_basha@yahoo.co.in plzzzzzzzzzzzzzzz

1576


In a sales interview if a person ask us how would you be able to sell our products in this recesion. How would i have to respond them.

1646