Introduction
So far, we've looked at the basics of Java and how to use simple constructs such as conditional statements and looping statements, and how methods are implemented in Java. These basic ideas are very important to understand and are useful when building simple programs. However, to build and maintain large and complex programs, the basic types and constructs do not suffice. What makes Java really powerful is the fact that it is an object-oriented programming language. It allows you to build and integrate complex programs effectively, while maintaining a consistent structure, making it easy to scale, maintain, and reuse.
In this lesson, we will introduce a programming paradigm called object-oriented programming (OOP), which lies at the core of Java. We will have a look at how OOP is done in Java and how you can implement it to design better programs.
We will start this lesson with a definition of OOP and the principles underlying it, will look at OOP constructs called classes and...