CS-201 Final Term Exams Preparation Virtual University With Answers

image
image
image

CS-201 Final Term Exams Preparation Virtual University

Sr. # Questions Answers Choice
1 A Pointer is a special variable that contain. Data values Memory Address Both data and values None of the given option
2 Which of the following is the correct C++ syntax to allocate space dynamically for an array of 10 int? new int(10) new int[10] ; int new(10) ; int new[10];
3 How many bytes will the pointer intPtr of type int move in the following statement? intPtr += 3 ; 3 bytes 6 bytes 12 bytes 24 bytes
4 Class is a user defined___________. Data type Memory referee Value None of the given options
5 Which one of the following is the declaration of overloaded pre-increment operator implemented as member function? Class-name operator +() Class-name operator +(int) Class-name operator ++() ; Class-name operator ++(int) ;
6 Which of the following statement is best regarding declaration of friend function? Friend function must be declared after public keyword Friend function must be declared after private keyword Friend function must be declared at the top within class definition It can be declared anywhere in class as these are not affected by the public and private keywords
7 All A template function must have at least ---------- generic data type. Zero One Two Three
Download This Set