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...

Whether there can be main inside another main?If so how does
it work?

Answer Posted / nilanjan

Surely. . It will just act like a recursive version of
main(), which will run infinite times if there is no
limiting condition specified.

Sample:

#include <stdio.h>

int main()
{
int static i = 0;

printf("\nFile is too big.");

while(i == 0)
{
i++;
main();
}
return 0;
}

Is This Answer Correct ?    21 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

If I have a char * variable pointing to the name of a function ..

1144


Write a code of a general series where the next element is the sum of last k terms.

1007


In c programming write a program that will print 10 multiples of 3 except 15,18,21 using looping

1442


Can the “if” function be used in comparing strings?

997


Where does the name "C" come from, anyway?

1098


What are the preprocessor categories?

1013


Why we use conio h in c?

1169


What is pass by reference in c?

1160


Write a program to reverse a linked list in c.

1084


How variables are declared in c?

1009


Explain what is wrong in this statement?

1083


Why is c called "mother" language?

1242


What are the advantage of c language?

1021


What is unary operator?

1065


What is bin sh c?

1005