Unlock all 48 lessons of Introduction to Java Programming 2.0Full course ₹40,000 · paid
Key Features of Java: Portability, Security and Threads
A free lesson from Skill-Lync's Introduction to Java Programming 2.0 course, on Grow by Skill-Lync · Last updated 16 Nov 2026 · Session: “Module 1 - Features of Java”
What will you learn in this free Introduction to Java Programming 2.0 lesson?
The instructor goes through the main features of Java, starting with simplicity, object orientation and the interpreter that lets one program run on Windows, Mac OS or Linux. The lesson then covers distributed support for internet protocols, security, robustness, automatic garbage collection, bytecode portability and multithreading.
- Java bytecode runs on any OS with an interpreter
- How garbage collection frees unused memory
- C++ features Java leaves out, like pointer arithmetic
- Multithreading as one program doing several tasks
What comes after lesson 2?
The next free lesson is lesson 3, “Java Ecosystem: JVM, JDK and Setting Up the Environment” (5 min). Later in Skill-Lync's Introduction to Java Programming 2.0 course (paid): lesson 4, Module 1 - Setting up the Environment; lesson 5, Module 1 - Your first Java code; lesson 6, Module 1 - Running and debugging. The full course has 48 lessons (12 h 0 min of video); see the course overview or its price and syllabus.
Lesson transcript
Machine transcript of the lesson audio (lightly cleaned). Technical terms may contain errors; the video is the reference.
Now, let's look at some of the features of Java. The very first and the most important features, I would say, is that Java is very, very simple. So, earlier, the programmers would have to write in a particular programming language in which they would have punch cards in a supercomputer, and then those cards would be run one by one in batches, and that was the whole process. You also know that machine does not understand any language other than zeros and ones. Now, imagine if you would have to code in that language which only involves zeros and ones.
Your brain would explode, right? You would not be able to write a very simple program as well. Today, the market is such that we can write complex programs. The programming language and the processes are in such a good place that we are able to output so much to an end user. How is that possible? That is possible with simple programming languages like Java. So, as you know, the first programming language, which became very, very famous, when object-oriented programming constructs were added to the C language, that became C++.
Java is not similar to C++, but then it avoids any poorly understood or confusing features of C++. Like, for example, there is no need of header files, pointer arithmetic, structures, unions, operator overloading, or virtual place classes in C++ if anybody is from that background. But Java is very easy. It's a high-level programming language, so it's not a machine language of zeros and ones. It is something which is easier to understand. It has avoided all the confusing aspects, and a person is able to easily learn and use it.
The other aspect, which is object-oriented programming, as I just said, that really changed the scenario of programming. So, earlier, let's say the C language was procedure-oriented. You did not care a lot about data. You cared about procedures on that data. So, you give me any data, I would do X, Y, Z things on that, and that was the main crux of how the programming language would work. But then, object-oriented concepts said that, no, data is not secondary. Data is primary, in fact. Our data or objects in real life are primary, right?
So, object-oriented programming is simply like real life. We have objects, and we have things which we can do with objects. Every object has some properties. Every object would have something which we can do with them. So, Java also took that concept of object-oriented programming from its very beginning. So, Java, from the beginning itself, was an object-oriented programming language, just like C++. And that's why we have all the advantages of object-oriented programming in that. Java is also an interpreted language, meaning that Java has an interpreter for each machine, each operating system on which it works.
So, here's the thing. There are a number of operating systems in this world, right? Would you mind writing different codes for different operating systems doing the same task? Of course not. You want that, I want to write just one code, and I want some mechanism in which that code should run on Windows operating system, Mac OS, or Linux, or different versions of Linux, all of that. So, that is really possible if you could have some sort of an interpreter, which will actually take the code and see to it that, oh, this is exactly what the user wants.
Now, let me just convert it into some form which would be very friendly for this particular OS on which I am installed. So, what it will say is that, see, this is the user program. I have converted it to what you want, and please execute that. That is the interpreter. So, it would take that Java bytecode, and I'll just explain what a bytecode is in a moment. So, it would take the Java bytecode, and it would run that, execute that directly on any machine on which an interpreter has been ported, okay?
Java is distributed, as in it was designed with the distributed environment of the internet in mind. So, internet uses all these protocols, right? TCP, IP, HTTP, FTP, all of that. So, Java has extensive support, extensive libraries for your routines of all these protocols, okay? So, we can simply use Java in any distributed environment, and it will be able to do all the communications with these protocols. Now, when you have a distributed environment, when you have a lot of communications, the main important aspect of any application is security, right?
So, Java is something which would help in that. It would help in enabling the construction of virus-free or tamper-free systems. And then again, Java is robust. There is strict typing in Java, which would help in error-free programming. So, it's not that your programs are not reliable. If you feel that your program is working on your machine, it would be working on the environment as well, if you have configured things properly. It is pretty robust. It does not break. It does not give errors in any other form, which you might not expect to.
And there is a lot of early checking of possible problems happening. So, Java gives a lot of that aspect, and that's why it becomes robust. So, if it is secure, if it is robust, if it can be worked on a distributed environment, what is that application which would definitely want to work with Java? Any guesses? Banking applications. So, banking applications generally use Java. So, even today, if you work for any banking application, you would realize that most of the times, it is on the Java programming language just because it is so secure and so robust.
Java is also a dynamic programming language in the sense that libraries can freely be added, new methods and instance variables. All of that can be added to Java libraries. The star of Java is actually automatic memory management or garbage collection. So, what happens is that you create data while you are coding your program. It may be that you do not really need that data henceforth. So, what used to happen earlier, like with C language, even today, there is a lot of memory issues which would happen just because the waste memory, which is not to be used, is not freed from the space.
It is as if your code is using a lot of memory, while in fact, it is not really using all of that memory. So, what Java does is that it collects all the useless data and it simply frees that memory to be available for any other data which you want to use or you want to create with your code. So, that automatic memory management really helped Java to be very, very efficient. Architectural neutral, of course, as I said, that whatever architecture is there of the machine or of the operating system, we do not care about that.
So, you have your Java code, what happens is that your Java compiler will convert that code to something known as bytecode, okay? So, once that bytecode is created, then that bytecode can be run on any different OS just because of the different interpreter of Java on that particular OS. So, that's why it becomes architecture neutral or you can say it becomes portable. So, how does it become portable? Just because it has a particular Java runtime system for that particular OS. And again, Java is having a lot of high performance and that's really important for applications, right?
And the last thing of Java, which is one of the most important things, is multi-threading. Java programs allow different threads and we will go into what exactly these threads are, how they work, how do they communicate, all of that. But in simple terms, let me put it in such a way that you have one program, but that one program can do multiple tasks at the same time. That is possible just because you have different threads which are doing those different tasks. And Java allows multitasking with using multiple threads running at the same time, okay?
So, that's a simple definition of that. Multi-threading means a single program having different threads executing independently at the same time, okay? So, I just have given you so much of information about Java. Now, if you did not understand any of that part, that's absolutely fine because I'm going to show you everything with practical examples. So, there you will definitely understand it. So, stay tuned with me. We have a lot to cover.