CBSE Computer Science - Revision Tour(Solved) CBSE Guess > eBooks > Class XII > CBSE Computer Science C++ Solved Revision Tour By Mr. Ravi Kiran COMPUTER SCIENCE C++ 2006 Delhi: 1.a) Name the header file to which the following below: (i) abs( ) (ii) isupper( ) 1 Ans) (i) abs( ) - math.h, stdlib.h, complex.h ,(ii)isupper( ) - ctype.h 1.e) Find the output of the following program.
2 Ans: Output: 2 2006 Outside Delhi: 1.a) Name the header file to which thefollowing belong: 1(i) pow ( ) (ii)random( ) 2 Ans: i) abs( ) - math.h, stdlib.h, complex.h (ii)random( ) - stdlib.h 1.e) Find the output of the following program.
2 Ans: Output -2 2005 Delhi: 1.a) Differentiate between a Call by Value and Call by Reference, giving suitable examples of each. 2 Ans: Call by value: In call by value method,tte called function creates a new set of variables and copies the values of arguments into them. The function does not have access to the original variables (actual parameters)and can only work on the copies of values it created. Passing arguments by value is useful when the original values are not to be modified. Program to illustrate the call by value method of function invoking:
Ans: Output: The original value is 10.Return value of function change() is 20.The value after function change() is over 10. Program to illustrate the call by Reference method of function invoking:
Output: The original value is 10. Return value of function change() is 20. The value after function change() is over 20.
CBSE Computer Science Solved Revision Tour By Mr. Ravi Kiran ( [email protected] ) |
|