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 scope of static variables in c language?

Answer Posted / dhanshri chabukswar

in c language the scope of a static variable depends on where it is declared
void func(){
static int x=0;
x++;
printf("%d",x);
}
scope - is x
out put- 123 if you call func()three times

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

the constant value in the case label is followed by a a) semicolon b) colon c) braces d) none of the above

1198


write a program to reverse a every alternetive words in a string in a place. EX: Input is "this is the line of text" Output should be "shit is eht line fo text" Please any one tell me code for that.

2025


What are the two forms of #include directive?

1100


What is the value of uninitialized variable in c?

977


Why do some versions of toupper act strangely if given an upper-case letter?

1037


Explain what is the difference between a free-standing and a hosted environment?

1126


Why calloc is better than malloc?

973


Write a program to reverse a linked list in c.

1066


What are keywords in c with examples?

1039


Explain how do you search data in a data file using random access method?

1070


What is #include stdio h?

1061


in ‘C’ language for Matrix Multiplication fails” Introspect the causes for its failure and write down the possible reasons for its failure.

7989


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

1116


What is uint8 in c?

1055


Explain goto?

1094