search
Log In
Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
1 vote
1.2k views

a class having no name

  1. is not allowed
  2. cannot have a constructor
  3. cannot have a destructor
  4. cannot be passed as an argument
in Object Oriented Programming
edited by
1.2k views

1 Answer

2 votes
 
Best answer
since this class dont have name it can not have constructor or destructor and it can neither be passed as argument.

so ans is B,C,D  

 

is quite useless, but you can specyfy a class without a name and then create instances of this class. Knowing that you can use the following:

selected by

Related questions

0 votes
1 answer
1
3.5k views
A struct is the same as a class except that (A) there are no member functions. (B) all members are public. (C) cannot be used in inheritance hierarchy. (D) it does have a this pointer
asked Feb 26, 2017 in Object Oriented Programming Sanjay Sharma 3.5k views
0 votes
1 answer
2
147 views
Which of the following is true? A static member of a class cannot be inherited by its derived class A static member of a class can be initialized only within the class it is a member of A static member of a class can be initialized before an object ... Since static member of a class is actually a global element, it does not require class/object qualifier to access it independently of class/object
asked Jun 16, 2016 in Object Oriented Programming Sanjay Sharma 147 views
0 votes
0 answers
3
44 views
If we have a n*n Bit-Array in which we have only 1's and 0's filled . Constraint is that in every row , 0 comes before 1 , so how to find the index of the row which has maximum no of 1's
asked Jul 26, 2018 in Algorithms radha gogia 44 views
0 votes
1 answer
4
...