Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


Is main() is used in the program,,see below example?

void main()
{
int i;
for(i=0;i<10;i++)
main();
}

Then what is the output of the program?

Answers were Sorted based on User's Feedback



Is main() is used in the program,,see below example? void main() { int i; for(i=0;i<10;i++)..

Answer / parvathi

it cgoes into infinite loop

Is This Answer Correct ?    11 Yes 1 No

Is main() is used in the program,,see below example? void main() { int i; for(i=0;i<10;i++)..

Answer / hari

it will go into an infinite loop.
cheers !!!

for further queries and discussions, just check these out !!!

http://forum.campusmaniac.com/
http://www.campusmaniac.com/

Is This Answer Correct ?    2 Yes 0 No

Is main() is used in the program,,see below example? void main() { int i; for(i=0;i<10;i++)..

Answer / sai

The given program is an infinite loop with no
output.Because it calls main() function with in the for
loop.
So the value of the i always '0' only.According to the for
loop condition the execution of the program goes false only
i>=10.Then when the condition in the for loop goes to false?

Is This Answer Correct ?    0 Yes 0 No

Is main() is used in the program,,see below example? void main() { int i; for(i=0;i<10;i++)..

Answer / anbu sankar

Always i value is zero.
This program comes under recusive concept.
In stack memory,always remaining statement address [(i.e)
after main]is stored.
so at one stage stack is filled by addresses. so
Segmentation falut...

Is This Answer Correct ?    0 Yes 0 No

Is main() is used in the program,,see below example? void main() { int i; for(i=0;i<10;i++)..

Answer / kalyan chukka

Loop will Repeated 10 times .in this program main function
is called it self 10 times.So the loop will repeated 10 times

Is This Answer Correct ?    1 Yes 4 No

Is main() is used in the program,,see below example? void main() { int i; for(i=0;i<10;i++)..

Answer / harshitha

the loop will be repeated for 10 times

Is This Answer Correct ?    2 Yes 12 No

Post New Answer

More C Interview Questions

What is meant by inheritance?

0 Answers  


how to find binary of number?

2 Answers  


I didn't count the ducks that I saw in line, but I do remember that one duck was in front of two ducks, another duck behind two ducks. How many ducks did I see?

2 Answers  


find the size of structure without using the size of function

1 Answers   Bosch,


What is the relationship between pointers and data structure?

0 Answers  


What is structure in c language?

0 Answers  


What is the general form of a C program?

0 Answers  


Magic square

0 Answers  


What is atoi and atof in c?

0 Answers  


What are the concepts introduced in OOPs?

3 Answers  


write a c prog for removing duplicate character from an array and sorting remaining elements using a single array

1 Answers  


Difference between Function to pointer and pointer to function

0 Answers  


Categories