Skip to main content

You Down With OOP? Yeah, You Know Me! Getting Started With Java

If you're looking to dive into the world of Java programming, you're in the right place! 

Even if you just want to dip your toes, getting started is easy. Windows users need simply visit  https://www.oracle.com/java/technologies/downloads/#jdk20-windows and download the Java Development Kit (JDK) of your choice. Latest version as of this post is JDK 20. Mac & Linux can click over to their OS links and download their respective installers as well. Run the program and follow the installation instructions. Next visit https://netbeans.apache.org/download/index.html and download the latest release or an older version if you wish. Latest release as of this post is NetBeans 17. Run the program and again follow the installation prompts. Viola! You've successfully installed Java and NetBeans IDE. 

Follow along this easy tutorial to write your first program:  https://docs.oracle.com/javase/tutorial/getStarted/cupojava/netbeans.html 


Since Java is an object-oriented programming language, it's important to know the fundamentals about object-oriented programming (OOP). There are 4 major principles of OOP - Encapsulation, Abstraction, Inheritance, and Polymorphism. 


Encapsulation - This is the hiding of data implementation by restricting access to the details of a class from the user. By doing so, changes can be made to the class with confidence that it would not break other code that calls upon that class for information. 

Abstraction - This is the process of identifying key characteristics or features of an object that distinguishes  it from other objects. This helps manage complexity by creating smaller and more manageable components. 

Inheritance - Objects can relate to each other and inherit properties and functionality from another. This allows the ability to create classes with common features of others thereby helping to eliminate duplicate code. 

Polymorphism - This is the ability of an object to take on many forms. "One Name, Many Forms". Multiple methods have the same name but slightly different functionality. Two types of polymorphism are overriding and overloading. 






Comments

Popular posts from this blog

Getting It All Sorted: Algorithmic Design & Data Structure

 Algorithmic design and data structure techniques are an important part in developing structured programs. They help to organize and optimize code for efficiency, scalability, and ease of maintenance. Follow me as we take a little dive into what it is and why it’s important.   An algorithm is a set of instructions that performs a specific task. Algorithmic design involves designing algorithms that are efficient, scalable, and easy to maintain. There are many different types of algorithms, and some are better suited for certain types of problems than others.   When designing algorithms, it is essential to consider the input and output requirements of the problem. For example, if you are designing an algorithm to sort a list of numbers, you need to consider the size of the list, the range of the numbers, and whether the list needs to be sorted in a specific order.   Data structure techniques involve organizing and manipulating data in ways to make it easy to ac...