#include<stdio.h>
int fun();
int i;
int main()
{
while(i)
{
fun();
main();
}
printf("hello \n");
return 0;
}
int fun()
{
printf("hi");
}
answer is hello.how??wat is tat while(i) mean?
Answer Posted / sudhir kumar sharma
if we try this program in case of above program we will come
to a conclusion that all the variable declared before main
are global and assigned a value by default to zero that's
why the while loop will not executed in the above program :)
#include<stdio.h>
#include<conio.h>
int a;
float b;
double c;
char d;
static int e;
int main()
{
clrscr();
printf("%d\n %f\n %d\n %c\n %d\n",a,b,c,d,e);
getch();
return 0;
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
When should the volatile modifier be used?
Can you please explain the scope of static variables?
What is pivot in c?
What is the right way to use errno?
The process of repeatedly running a set of computer instructions until some condition is specifed a) condition b) sequential condition c) global d) iteration
What are actual arguments?
What is a c token and types of c tokens?
What is the method to save data in stack data structure type?
What is the best way of making my program efficient?
Explain the use of fflush() function?
What is pass by reference in functions?
What are enums in c?
please can any one suggest me best useful video tutorials on c i am science graduate.please help me.u can email me to sas29@in.com
What is the use of parallelize in spark?
How can I run c program?