GeekInterview.com
   Home |  Tech FAQ  |   Interview Questions |  Placement Papers |  Tech Articles |  Learn |  Freelance Projects |  Online Testing |  Geeks Talk |  Job Postings |  Knowledge Base | Site Search |  Add/Ask Question

  GeekInterview.com  >  Interview Questions  >  Concepts  >  OOPS

 Print  |  
Question:  What are enumerators? and what are in-line functions? giv ans with eg.



November 11, 2007 03:24:49 #1
 kamal7725   Member Since: November 2007    Total Comments: 14 

RE: What are enumerators? and what are in-line functions? giv ans with eg.
 
enum's are data type, while in-line functions are function.
enum are integer repesentation in understandable form like-
enum {
monday,
tuesday,
...
...
sunday
};

now if compare like
if( 1== sunday) condition will return true.


in-line functions are the ones which get insert into the code where they are called.
The difference between function and in-line function is no call will be made to the in-line function during execution. using this one can improve execution performance. this capability is compiler dependent and also depend on the optimization settings.
     

 

Back To Question