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

there is two conditions ,

1. while using for loop for printing 1 to 50 no's simulteneous
2. while using printf functios for printing 1 to 50 no's simulteneous with or without using variables

who will take more time for compiling and execution?
explain in details with reason?

Answer Posted / avanish pal

For loop will take more time for compiling and execution
because when we execute the program, flow of control frist
print 1 and after that returns to the condition and than
printed 2 this process repeated 50 times where as in simple
printf it straight print all numbers.

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Simplify the program segment if X = B then C ← true else C ← false

3015


What is difference between structure and union in c programming?

1107


Explain how can I manipulate strings of multibyte characters?

1206


Write a C program to accept a matrix of any size. Find the frequency count of each element in the matrix and positions in which they appear in the matrix

2008


What are called c variables?

1065


How do you use a 'Local Block'?

1171


In a header file whether functions are declared or defined?

1126


What are the different types of pointers used in c language?

1046


Why is c platform dependent?

1090


What is the difference between constant pointer and constant variable?

1224


what is the structure pointer?

2123


What is operator precedence?

1204


cin.ignore(80, _ _);This statement a) ignores all input b) ignores the first 80 characters in the input c) ignores all input till end-of-line d) iteration

1106


How are structure passing and returning implemented?

1037


What does c mean in standard form?

1173