what will be the output of the following program, justify?
#define TEST
int TEST getdata()
{
static i;
i+=10;
return i;
}
main()
{
int k;
k = getdata();
}
Answer Posted / rama krishna sidhartha
Since there is no output statement in this program there
output will not be displayed.
The output statement must be as follows :
printf("%d",k);
Then the output will be 10.
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
I was asked to write a program in c which when executed displays how many no.of clients are connected to the server.
What does malloc () calloc () realloc () free () do?
How can you convert integers to binary or hexadecimal?
What is an arrays?
How can you increase the size of a statically allocated array?
What is the basic structure of c?
What is malloc() function?
Explain null pointer.
What are the ways to a null pointer can use in c programming language?
How can I read a binary data file properly?
what is a NULL Pointer? Whether it is same as an uninitialized pointer?
Can two or more operators such as and be combined in a single line of program code?
Explain the difference between #include "..." And #include <...> In c?
Can you subtract pointers from each other? Why would you?
Can we increase size of array in c?