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
What is main () in c language?
How are variables declared in c?
What is meant by gets in c?
What is a example of a variable?
Implement bit Array in C.
Explain can static variables be declared in a header file?
What is New modifiers?
What is a pointer in c plus plus?
What are the advantages of external class?
What is your stream meaning?
How to set file pointer to beginning c?
What is union in c?
Which is the best website to learn c programming?
What is pointers in c?
Can we replace the struct function in tree syntax with a union?