Skip to content

Rahul-150705/OOP

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

36 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

OOP

πŸ“… Day 1 β†’ Class, Object & Constructors

Learn how to create classes and objects.

Understand instance variables and methods.

Implement constructors (default & parameterized).

βœ… Task: Create a Student class with id, name, and a constructor to initialize values.

πŸ“… Day 2 β†’ Static Keyword

Learn about static variables, static methods, and static blocks.

Understand the difference between instance vs static members.

βœ… Task: Create a Counter class that tracks how many objects have been created using a static variable.

πŸ“… Day 3 β†’ Inheritance & super()

Learn how one class can inherit from another.

Understand single inheritance and multilevel inheritance.

Use super() to call parent class constructors and methods.

βœ… Task: Create a Vehicle class β†’ extend it into Car and Bike. Use super() to initialize parent properties.

πŸ“… Day 4 β†’ Polymorphism + Mini Project

Learn method overloading (compile-time polymorphism).

Learn method overriding (runtime polymorphism).

Understand dynamic method dispatch.

βœ… Mini Project: Build a Vehicle Rental System where Car, Bike, and Truck calculate rental cost differently using polymorphism.

πŸ“… Day 5 β†’ Abstraction & Encapsulation

Learn Encapsulation β†’ wrapping data (private fields + getters/setters).

Learn Abstraction β†’ hiding implementation, showing only essential features.

Understand difference:

Encapsulation = data hiding

Abstraction = implementation hiding

βœ… Task: Build a BankAccount class with private balance and public methods (deposit(), withdraw(), getBalance()) to demonstrate encapsulation & abstraction.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages