OOP Important Questions
OOP Important Questions
- Focuses on procedures/functions.
A: - JDK: Java Development Kit, used to write and compile Java programs.
- JRE: Java Runtime Environment, executes Java programs.
A: Inheritance allows a class to inherit properties and methods from another class. Types:
- Single
- Multilevel
- Hierarchical
Note: Java does not support multiple inheritance directly due to ambiguity.
- Interface: Only abstract methods (prior to Java 8), default and static methods allowed since Java 8.
Example:
```java
package mypack;
```