#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 / parul_kul
As "int i" is not defined/declared inside any function, by
default it is declared as external variable not as auto.
Thats why, it takes the 0 as its default value.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
Take an MxN matrice from user and then sum upper diagonal in a variable and lower diagonal in a separate variables. Print the result
Ow can I insert or delete a line (or record) in the middle of a file?
What is the difference between procedural and functional programming?
What are the advantages of c language?
Why is not a pointer null after calling free? How unsafe is it to use (assign, compare) a pointer value after it is been freed?
What is the purpose of the following code? Is there any problem with the code? void send(int count, short *to, short *from) { /* count > 0 assumed */ register n = (count + 7) / 8; switch (count % 8) { case 0: do { *to = *from++; case 7: *to = *from++; case 6: *to = *from++; case 5: *to = *from++; case 4: *to = *from++; case 3: *to = *from++; case 2: *to = *from++; case 1: *to = *from++; } while (--n > 0); } }
How can you convert integers to binary or hexadecimal?
What is unary operator?
i have to apply for the rbi for the post of officers. i need to know abt the entrance questions whether it may be aps or techinical....
how to create duplicate link list using C???
Explain about the constants which help in debugging?
1) write a program to generate 1st n fibonacci prime numbers using Nested if 2) write a program to generate twin prime numbers from m to n using nested if 3) write a program to check whether a given integer is a strong number or not using nested if 4) Write a program to generate prime factors of a given integer using nested if 5)write a program to generate prime numbers from m to n using nested if 6)write a program to generate perfect numbers from m to n using nested if 7)write a program to generate the pallindromes from m to n using neste if 8)write a program to generate armstrong numbers from m to n using nested if 9)write a program to generate strong numbers from m to n using nested if
Can you please explain the difference between exit() and _exit() function?
how to execute a program using if else condition and the output should enter number and the number is odd only...
Tell me when would you use a pointer to a function?