Anda di halaman 1dari 2



B.Tech-IT,2nd Year,4th Sem

Assignmnet No.3

1. What is an interface? Give its syntax.
2. How will you extend one interface by other interface?
3. How will you implement the concept of multiple inheritance using interfaces?
4. How does java know that the class we create implements a particular interface?
5. Differentiate class and interface.
6. List out the similarities between interfaces and classes.
7. What is inheritance? How does it create new classes?
8. Describe different forms of Inheritance in java with examples.
9. Give the syntax of Single inheritance, Multilevel inheritance, and Hierarchical
10. What is a Package?
11. What is the default package in java? Give its syntax.
12. How do we add a class or an interface to a package?
13. How will you protect a class from accidental access?
14. What is an object class?
15. When is a class or method declared as final?
16. When is a class or method declared as abstract?
17. How is a superclass constructor or method invoked?
18. When is a member of a class declared as static?
19. Compare and contrast overloading and overriding methods.
20. Define Polymorphism. What are the different types of polymorphism?
21. What is Dynamic method dispatch or run rime polymorphism?
22. List out the different levels of access protection in java.
23. What is a wrapper class? What are its applications?
24. What is meant by Late binding?

1. How is interface used to support multiple inheritance? Explain with a program.
2. Describe the various levels of access protection available in packages and their
implications with an example program.
3. Explain the need of package in Java. Explain accessibility rules for package. Also explain
how members of a package are imported. Write java program to create your own package
for finding area of different shapes.
4. What is method overloading? How it is different from method overriding? Write a java
program to explain overloading and overriding of methods.
5. Explain in detail about creating and accessing packages with an example program.
6. Explain Dynamic method dispatch with one example program.
7. Describe Method overriding. Explain it with an example.
8. Write short notes on:
i) Upcasting
ii) Downcasting
9. Explain in detail about different types of Inheritance with an example
10. Compare and contrast Java and C++.
11. Explain in detail about Wrapper classes with an example.
12. Explain about Native methods with suitable examples.