There are 2 classes defined as below
public class A
{
class B b;
}
public class B
{
class A a;
}
compiler gives error. How to fix it?
Answer Posted / santhosh
by Forward declaring,
class B;
public class A
{
class B b;
}
public class B
{
class A a;
}
Is This Answer Correct ? | 11 Yes | 1 No |
Post New Answer View All Answers
What is encapsulation selenium?
What is variable example?
Why is object oriented programming so hard?
write a C++ program for booking using constructor and destructor.
which feature are not hold visual basic of oop?
assume the program must insert 4 elements from the key board and then do the following programs.sequential search(search one of the elements),using insertion sort(sort the element) and using selection sort(sort the element).
What is the benefit of oop?
What are two types of polymorphism?
Is enum a class?
Can we create object of abstract class?
What is polymorphism what are the different types of polymorphism?
What are the benefits of oop?
What is polymorphism in oops?
What is abstraction encapsulation?
What is the full form of oops?