What does static mean in c?
Answer / sasi
Whenever Static is used with a Variable declaration .. it defines that the last updated value of the Variable will not be deleted after the process of a program .
Eg : #include <stdio.h>
int main() {
func();
func();
func();
}
void func() {
static int i=2;
i=i+1;
printf("%d
",i);
return 0;
}
Output :
3
4
5
| Is This Answer Correct ? | 0 Yes | 0 No |
What is 2 d array in c?
what is the difference between these initializations? Char a[]=”string”; Char *p=”literal”; Does *p++ increment p, or what it points to?
How do you convert a decimal number to its hexa-decimal equivalent.Give a C code to do the same
how c source file in converted to exe file
What is a struct c#?
What do you mean by Recursion Function?
Explain bitwise shift operators?
program for following output using for loop? 1 2 2 3 3 3 4 4 4 4 5 5 5 5 5
write a program to display the numbers in the following 4 4 3 3 2 2 1 1 0 1 1 2 2 3 3 4 4
How can you determine the size of an allocated portion of memory?
What is binary tree in c?
Is exit(status) truly equivalent to returning the same status from main?