Can constructors be parameterized?
Answer / Rafi Ullah Baqai
Yes, constructors can have parameters in Java. The constructor takes input values (arguments) and uses them to initialize the object's state. Constructors are called when an object is created using the new keyword.
| Is This Answer Correct ? | 0 Yes | 0 No |
What is virtual multiple inheritance?
What is the use of interface?
What is a try/ catch block?
Can encapsulation be called as a security device?
What is the function of messaging metaphor?
Difference: 'uses', 'extends', 'includes'
7 Answers Cognizant, Protech, TY, University,
Classes and structs support inheritance. Is this statement true or false?
What is difference between polymorphism and normalization?
Explain the concept of multiple inheritance (virtual inheritance). Write about its advantages and disadvantages?
What is the difference between an Abstract class and Interface?
Does a class inherit the constructor of its super class?
What is static polymorphism?