0% found this document useful (0 votes)
2 views3 pages

Java Core Concepts Questions

The document outlines Java core and advanced concepts, providing explanations and 10 coding questions for each topic. Key topics include classes and objects, methods, inheritance, polymorphism, and encapsulation, among others. Each section is designed to enhance understanding through practical coding exercises.

Uploaded by

EARNING FACTS
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views3 pages

Java Core Concepts Questions

The document outlines Java core and advanced concepts, providing explanations and 10 coding questions for each topic. Key topics include classes and objects, methods, inheritance, polymorphism, and encapsulation, among others. Each section is designed to enhance understanding through practical coding exercises.

Uploaded by

EARNING FACTS
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

This sheet contains Java core and advanced concepts explained with 10 coding questions for each topic.

1. Classes and Objects

Explanation:

A class is a blueprint for objects. An object is an instance of a class.

Example:

class Car {

String color;

int speed;

void drive() {

System.out.println("Car is driving");

Questions:

1. Create a class named Student with fields name, age and rollNumber.

2. Instantiate two objects of the Student class.

3. Create a method in Student class to display student info.

4. Create a class named BankAccount with deposit and withdraw methods.

5. Implement a class Library with books as an array.

6. Create a class Mobile with attributes brand, model and price.

7. Instantiate Mobile class using a constructor.

8. Create a class Rectangle with methods to calculate area and perimeter.

9. Implement a class Employee with a method to calculate bonus.

10. Create a class Book with static variable for total books.
2. Methods

Explanation:

Methods define behaviors of a class.

3. Constructors and its types (Default, Parameterized, Copy)

4. Method Overloading

5. Inheritance and its types (Single, Multilevel, Hierarchical)

6. Polymorphism and its types (Compile-time, Runtime)

7. Method Overriding

8. Access Modifiers (private, public, protected, default)

9. Types of Variables (Local, Instance, Static)

10. Scope of Variables

11. Abstract Classes

12. Interfaces

13. Multiple Inheritance using Interface


14. Encapsulation

15. AWT and its components with syntax

16. Event Handling

17. Event Delegation Model

18. Threads

19. Thread Life Cycle

20. Creating Threads (Thread class, Runnable interface)

Each topic will be expanded with explanation and 10 coding questions.

You might also like