Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

main()
{
char as[] = "\\0\0";
int i = 0;
do{
switch( as[i++]) {case '\\' : printf("A");
break;
case 0 : printf("B");
break;
default : printf("C");
break;
}}
while(i<3);
}

Answer Posted / lakshman

ABC is correct answer, because in first condition switch(0)=\ then it prints the character "A" ,then its break. in next condition switch(1)=0 then its prints the character "B" . In final condition switch(2)=,it does not match any case value so default condition is executed that means character "C" will print, so the final answer is ABC

Is This Answer Correct ?    2 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is static and volatile in c?

1234


How many bytes are occupied by near, far and huge pointers (dos)?

1171


Explain the difference between exit() and _exit() function?

1176


What is the use of ?: Operator?

1146


What are global variables and how do you declare them?

1113


I have seen function declarations that look like this

1056


How will you write a code for accessing the length of an array without assigning it to another variable?

1060


How do you define structure?

1055


Explain the Difference between the New and Malloc keyword.

1153


What is self-referential structure in c programming?

1230


How can a program be made to print the line number where an error occurs?

1091


What is the explanation for prototype function in c?

996


What is the difference between a string and an array?

1220


What is indirection?

1114


What are static variables in c?

1092