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...

What is the output for the program given below

typedef enum grade{GOOD,BAD,WORST,}BAD;
main()
{
BAD g1;
g1=1;
printf("%d",g1);
}

Answer Posted / fefrf

In linux you get following error
enum.c:2: error: `BAD' redeclared as different kind of symbol
enum.c:2: error: previous declaration of `BAD'

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Describe static function with its usage?

1215


Explain what is the difference between far and near ?

1112


what is stack , heap ,code segment,and data segment

2702


Explain how can I convert a string to a number?

1104


what are the advantages of a macro over a function?

1146


What is the right type to use for boolean values in c? Is there a standard type? Should I use #defines or enums for the true and false values?

1061


What does *p++ do? What does it point to?

1065


What is a structure and why it is used?

1229


What is an lvalue?

1066


What does s c mean in text?

1098


What is meant by type specifiers?

1139


How does placing some code lines between the comment symbol help in debugging the code?

1006


This is a variation of the call_me function in the previous question:call_me (myvar)int *myvar;{ *myvar += 5; }The correct way to call this function from main() will be a) call_me(myvar) b) call_me(*myvar) c) call_me(&myvar) d) expanded memory

1282


Explain goto?

1163


What is the use of #include in c?

1089