Contents

The function is declared with ……. If it does not have any return type.
a) long                                   
b) double
c) void                                  
d) int

c

The argument of a function is separated with……
a) comma (,)                        
b) semicolon (;)
c) colon (:)                            
d) none of these

a

The variables inside parenthesis of function declaration have…… level access.
a) local                                 
b) global
c) module                             
d) universal

a

What is the output of following function?
int divide (int a, int b=2)
a) variable b is integer and value 2 
b) variable a and b integer type
c) variable b is international scope  
d) variable b have 
value 2 if not specified

d

What is the output of following function?
int x; fun(x,3);
void fun (int a, int &b) {b=a*5+1;}
a) 16
b) 32                      
c) 14                      
d) 0

a

What is the output of following function?
int ppp(int k) { if(k<1) return k;}
else return k+ppp(k/2);}
a) 13      
b) 15                      
c) 16                      
d) 7

c