The inheritance property is used when there is an IS-A relationship between classes: TRUE or FALSE.
Official theoretical question paper for Object Oriented Programming (PCC-CS503) conducted by Maulana Abul Kalam Azad University of Technology. All questions from Groups A, B, and C are reproduced below with marks weightings.
The inheritance property is used when there is an IS-A relationship between classes: TRUE or FALSE.
Which container class doesn't contain title bar and menu bars but it can have other components like button, text field etc.?
A class member declared protected becomes a member of subclass of which type?
Which keyword is used to access the features of a package?
Which of the following statements are true for interfaces in java? i) Objects of an interface cannot be created. ii) All the methods of an interface are either abstract or default or static. iii) It does not contain constructors.
In the model-view-controller (MVC) architecture, the model defines the ________ layer.
All collection classes are available in ________ package.
What would be the possible output if a constructor is declared with a return type? a) Compilation error b) Runtime error c) Compilation and runs successfully d) Only String return type is allowed
main() method can be overloaded in Java. The above statement is true or false?
A class inheriting an abstract class does not define or implement all of its abstract methods is called ________ class.
What types of polymorphism is used in the following java program. class Paint { public void Color(int x) {...} public void Color(int x, int y) {...} public void Color(int x, int y, int z) {...} }
What is the output of following Java code? class Test { private int a = 4; private int b = 1; void getSum(int a, int b) { a = a; b = b; System.out.println(this.a + this.b);} } public class Main { public static void main(String args[]) { Test T = new Test(); T.getSum(3, 5); } }
Explain different features of object oriented programming?
What are the differences between Procedural programming language and Object oriented programming language?
What is the use of static keyword in java? Write a program to explain the use of static variable and static method in java.
Explain the benefit of using interface in java with the help of an example.
Why multiple inheritance can be implemented by using Interfaces but not by classes? Explain with an example.
What is parametric and non parametric constructor? Explain with suitable example.
Illustrate the use of the this keyword with a suitable program.
What is constructor overloading? Explain it with a suitable example.
What are the advantages of using design pattern in an organization?
Explain different types of design patterns with their use.
Explain the concept of model view controller pattern. What are the advantage of using it?
Create a class shape with data members dimension1,dimension2, area. Write an abstract method calculate_area in it. Create two child classes circle, triangle and override the calculate_area method in the child classes.
How run time polymorphism is achieved by using method overriding explain with respect to the problem statement given in part (a).
What is super keyword. Explain its use with an example program.
Write a program using swing to add two numbers and display the result.
Explain the working mechanism of Event delegation model.
Explain the concept of iterator design pattern.
Explain its working with a suitable program.
What is a final method? explain with an example.