Latest Activity In Study Groups

Join Your Study Groups

VU Past Papers, MCQs and More

We non-commercial site working hard since 2009 to facilitate learning Read More. We can't keep up without your support. Donate.


DEAR'S Fellows .

                        please share ur Quiz 2 of cs304 here , must be help each others . 

                        i ll fully try to upload quiz 100% solution soon 

         Thanks.

         Regards. 

                            Umair sid 

Views: 3233

Replies to This Discussion




Identify which of the following overloaded operator function's declaration is appropriate for the given call? Rational_number_1 + 2.325 Where Rational_number_1 is an object of user defined class Rational_number. 
Select correct option: 

Rational_number operator+( Rational_number & obj); 
None of the given choices 
Rational_number operator+(Rational_number &obj, double& num); 
operator+(double& obj); 


In _______________ a pointer or reference to an object is created inside a class 
Select correct option: 

Aggregation 
Composition 
Seperation 
None of the given 
Sub-Object can not be initialized using the constructor 
Select correct option: 

True 
False 

To initialize an array of objects, only _____________ will be called 
Select correct option: 

Defualt Constructor 
Overloaded Constructor 
Default Object 
None of the above 

Let Suppose a class Student with objects std1, std2, and std3. For the statement std3 = std1 - std2 to work correctly, if the overloaded - operator must 
Select correct option: 

take two arguments. 
None of the given choices 
take single argument 
take three arguments 

Copy constructor is called when: 
Select correct option: 

An object is created in term of pre existence object 
An object is created 
An object is initialized 
None of the given 


Which of the following operator doesn't take any argument if overloaded? 
Select correct option: 




None of the given choices 

 
Object can be declared constant with the use of Constant keyword. 
Select correct option: 

True 
False 

 
Always make pointer to null, whenever dynamic memory is deleted. 
Select correct option: 

True 
False 

 

__________ provide the facility to access the data member. 
Select correct option: 

accesser function 
private function 
inline function 
None of the given 

umair sid 

some of answers here ... 

2= aggregation 

4= default constructor 

6= an object is created 

8 true 

9= true

10= accesser function 

Thanks .. 

regards....... umair sid 

1=

 Rational_number operator+(Rational_number &obj, double& num);
 

 + (ℛ((ὗмДἷℛ ṩἷD )ℛ))♥ gud & thanks 

Note @ All: You don’t need to go any other site for this assignment/GDB/Online Quiz solution, Because All discussed data of our members in this discussion are going from here to other sites. You can judge this at other sites yourself. So don’t waste your precious time with different links.

welcome Sir !

ooye aap ka b yeah sub hea!!!!!

1              Identify which of the following overloaded operator function's declaration is appropriate for the given call? Rational_number_1 + 2.325 Where Rational_number_1 is an object of user defined class Rational_number.

 Select correct option:

 Rational_number operator+( Rational_number & obj);

 None of the given choices

 Rational_number operator+(Rational_number &obj, double& num);

 operator+(double& obj);

2              In _______________ a pointer or reference to an object is created inside a class

 Select correct option:

 Aggregation

 Composition

 Seperation

 None of the given

3              Sub-Object can not be initialized using the constructor

 Select correct option:

 True (not clear)

 False

4              To initialize an array of objects, only _____________ will be called

 Select correct option:

 Defualt Constructor

 Overloaded Constructor

 Default Object

 None of the above

5              Let Suppose a class Student with objects std1, std2, and std3. For the statement std3 = std1 - std2 to work correctly, if the overloaded - operator must

 Select correct option:

 take two arguments.

 None of the given choices

 take single argument

 take three arguments

6              Copy constructor is called when:

 Select correct option:

 An object is created in term of pre existence object

 An object is created

 An object is initialized

 None of the given

7              Which of the following operator doesn't take any argument if overloaded?

 Select correct option:

 /

 -

 +

 None of the given choices  

8              Object can be declared constant with the use of Constant keyword.

 Select correct option:

 True

 False  

9              Always make pointer to null, whenever dynamic memory is deleted.

 Select correct option:

 

 True

 False

10           __________ provide the facility to access the data member.

 Select correct option:

 

 accesser function

 private function

 inline function

 None of the given

Please Share your online Quizzes here to help each other.thanks

2nd quiz cs304

some of more MCQ's of today quiz . plz put here the corret answer of those .
thanks .
Umair Sid

QUIZ NO # 2 CS304

Person” class is composed off “Nationality” class. What will be the order of execution of constructor of “Keyboard” class and “Keys” class

First Constructor:: Nationality..
Second Constructor:: Person..

First Constructor:: Person..
Second Constructor:: Nationality..

The direction specifies which object contains the other object. In aggregation direction is must

Yes
No

Select correct line of code for inheritance relationship between “Account” class and “SavingAccount” class. “Account” is parent class while “SavingAccount” is child clas





class SavingAccount : public Account
class Account: public SavingAccount
class SavingAccount :: public Account
class Account :: public SavingAccount


“Keyboard” class is composed off “keys” class. What will be the order of execution of destructor of “Keyboard” class and “Keys” class

First Detructor::Keys..
Second Destructor::Keyboard..

First Destructor:: Keyboard..
Second Destructor:: Keys..

Select correct line of code for inheritance relationship between “Keys” class and “StandardKeys” class. “Person” is parent class while “StandardKeys” is child class.

class StandardKeys: public Keys
class Keys: public StandardKeys
class StandardKeys:: public Keys
class Keys:: public StandardKeys

Select correct line of code for inheritance relationship between “Gender” class and “Male” class. “Gender” is parent class while “Male” is child class.
class Male: public Gender
class Gender: public Male
class Male:: public Gender
class Gender:: public Male

What will be most appropriate C++ data type for variable “InterestRate

Int
long int
double
float

Select correct line of code for composition relationship between “Keyboard” class and “Keys” class

class keyboard { Keys type;};
class keys{ KeyBoard type; };
class keyboard : private keys
class keys: private KeyBoard

Method “getInterestRate()” should belongs to class

Account()
SavingAccount()
CurrentAccount()
None of the given options

Can we access methods of composed object in the same way as we can access methods of other objects?


Yes
No

Please can answer the above quiz.

Identify which of the following overloaded operator function's declaration is appropriate for the given call? Rational_number_1 + 2.325 Where Rational_number_1 is an object of user defined class Rational_number. 
Select correct option: 
Rational_number operator+( Rational_number & obj); 
None of the given choices 
Rational_number operator+(Rational_number &obj, double& num); 
operator+(double& obj); 


In _______________ a pointer or reference to an object is created inside a class 
Select correct option: 
Aggregation 
Composition 
Seperation 
None of the given 


Sub-Object can not be initialized using the constructor 
Select correct option: 
True 
False 

To initialize an array of objects, only _____________ will be called 
Select correct option: 
Defualt Constructor 
Overloaded Constructor 
Default Object 
None of the above 

Let Suppose a class Student with objects std1, std2, and std3. For the statement std3 = std1 - std2 to work correctly, if the overloaded - operator must 
Select correct option: 
take two arguments. 
None of the given choices 
take single argument 
take three arguments 


Copy constructor is called when: 
Select correct option: 
An object is created in term of pre existence object 
An object is created 
An object is initialized 
None of the given 


Which of the following operator doesn't take any argument if overloaded? 
Select correct option: 




None of the given choices 

 
Object can be declared constant with the use of Constant keyword. 
Select correct option: 
True 
False 

 
Always make pointer to null, whenever dynamic memory is deleted. 
Select correct option: 
True 
False 

 

__________ provide the facility to access the data member. 
Select correct option: 
accesser function 
private function 
inline function 
None of the given 



Person” class is composed off “Nationality” class. What will be the order of execution of constructor of “Keyboard” class and “Keys” class

First Constructor:: Nationality..
Second Constructor:: Person..


First Constructor:: Person..
Second Constructor:: Nationality..

 


The direction specifies which object contains the other object. In aggregation direction is must

Yes
No

 


Select correct line of code for inheritance relationship between “Account” class and “SavingAccount” class. “Account” is parent class while “SavingAccount” is child clas

class SavingAccount : public Account
class Account: public SavingAccount
class SavingAccount :: public Account
class Account :: public SavingAccount


“Keyboard” class is composed off “keys” class. What will be the order of execution of destructor of “Keyboard” class and “Keys” class

First Detructor::Keys..
Second Destructor::Keyboard..

First Destructor:: Keyboard..
Second Destructor:: Keys..


Select correct line of code for inheritance relationship between “Keys” class and “StandardKeys” class. “Person” is parent class while “StandardKeys” is child class.

class StandardKeys: public Keys
class Keys: public StandardKeys
class StandardKeys:: public Keys
class Keys:: public StandardKeys

Select correct line of code for inheritance relationship between “Gender” class and “Male” class. “Gender” is parent class while “Male” is child class.
class Male: public Gender
class Gender: public Male
class Male:: public Gender
class Gender:: public Male

What will be most appropriate C++ data type for variable “InterestRate
Int
long int
double
float

Select correct line of code for composition relationship between “Keyboard” class and “Keys” class

class keyboard { Keys type;};
class keys{ KeyBoard type; };
class keyboard : private keys
class keys: private KeyBoard

 

 

 

 


Method “getInterestRate()” should belongs to class

Account()
SavingAccount()
CurrentAccount()
None of the given options

Can we access methods of composed object in the same way as we can access methods of other objects?
Yes
No

The sub-object’s life is not dependant on the life of master class in ___________.

 Composition

Aggregation

Seperation

non of the given

 

correct line of code for inheritance relationship between “Nationality”

class and “Foreigner” class. “Nationality” is parent class while

“Foreigner” is child class.

class Foreigner: public Nationality

class Nationality: public Foreigner

class Foreigner:: public Nationality

 

Select correct line of code for aggregation relationship between “Person” class and “Phone” class.

 class Person  { Phone * p; };

class Phone { Person  * p; };

class Person  { Phone p; };

class Phone { Person   p; };

 

In ______________destructor of sub-object is called after destructor of master class.

smilechat: options

Aggregation

Composition

Inheritance

Association

 

correct line of code for inheritance relationship between “Gender” class

and “Female” class. “Gender” is parent class while “Female” is child

class.

class Female: public Gender

class Gender: public Female

class Female:: public Gender

class Gender:: public Female

 

 

 

 

Account” is parent class while “CurrentAccount” is child class. Can I inherit the destructor of “account” class?

Yes

no

 

Select correct line of code for aggregation relationship between “Person” class and “Address” class.

class Person  { Address * a; };

class Address  { Person  * a; };

class Person  { Address  a; };

class Address  { Person   a; };

 

 

 

In ______________constructors of the sub-objects are always executed before the constructors of the master class.

Select correct option:

Aggregation

Composition

Inheritance

Association

 

What will be most appropriate C++ data type for variable “MinimumBalance”?

Select correct option:

int

long int

float

double

 all solved today quiz

RSS

© 2021   Created by + M.Tariq Malik.   Powered by

Promote Us  |  Report an Issue  |  Privacy Policy  |  Terms of Service