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

Install and Configure JDK on Windows

Uploaded by

narmadha
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)
6 views3 pages

Install and Configure JDK on Windows

Uploaded by

narmadha
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

Step 1: Download the JDK installer

Go to a web browser and search for "Oracle Java download" to find the official Oracle website.

Click on the "Download Java" button or the link for the latest JDK version.

Navigate to the "Windows" tab and download the x64 MSI installer or .exe file.

Step 2: Run the installer

Once the download is complete, run the installer file from your downloads folder.

Follow the prompts in the installation wizard. The default installation path is usually C:\Program
Files\Java\jdk-version, and you can leave it as is.

Allow the installer to make changes to your device when prompted.

Click "Close" when the installation is complete.

Step 3: Set environment variables (for developers)

Search for and open "Edit the system environment variables" in the Windows search bar.

Click the "Environment Variables..." button.

Under "System variables," select "Path" and click "Edit".

Click "New" and paste the path to the Java bin folder (e.g., C:\Program Files\Java\jdk-version\bin), then click
"OK".

Click "New" again for JAVA_HOME, set the variable name to JAVA_HOME, and paste the path to the JDK
folder (e.g., C:\Program Files\Java\jdk-version), then click "OK".

Click "OK" on all remaining windows to close them.

Step 4: Verify the installation

Open a new Command Prompt window.

Type java -version and press Enter.

If the installation was successful, you will see the installed Java version number displayed, instead of an
error message.

Java Virtual Machine (JVM)

What it is: An abstract machine that provides the runtime environment for executing Java bytecode.

Function: It takes the compiled bytecode and converts it into machine-specific instructions.

Key feature: It is platform-independent, which is the basis for Java's "write once, run anywhere" principle.

Java Runtime Environment (JRE)


What it is: A software package that provides the resources to run Java applications.

Function: It contains the JVM and the core class libraries that the JVM needs to execute programs.

Key feature: It is platform-dependent because it includes the platform-specific implementation of the JVM.
You cannot use the JRE to develop programs; it is for running them.

Java Development Kit (JDK)

What it is: A comprehensive software development kit for creating Java applications.

Function: It includes everything in the JRE, plus a collection of development tools like compilers, debuggers,
and archiving tools.

Key feature: It is platform-dependent and is required for development. If you want to compile and build
Java programs, you need the JDK.

Features of Java:

Java is a widely used, high-level, object-oriented programming language known for its robust features. Key
features include:

Platform Independence:

• Java's "Write Once, Run Anywhere" (WORA) principle is achieved through the Java Virtual Machine
(JVM).

• Java code is compiled into platform-independent bytecode, which can then be executed on any
system with a compatible JVM, regardless of the underlying hardware or operating system.

Object-Oriented Programming (OOP):

• Java is a true object-oriented language, supporting core OOP concepts like encapsulation,
inheritance, polymorphism, and abstraction.

• Programs are structured around classes and objects, promoting modularity and reusability.

Robustness:

• Java emphasizes reliability through strong memory management, automatic garbage collection
(reducing memory leaks), exception handling, and strict type-checking mechanisms.

• These features contribute to stable and secure applications.

Security:

• Java incorporates built-in security features, including bytecode verification, a secure class-loading
mechanism, runtime security checks, and a sandboxing model to prevent untrusted code from
harming the host system.

Multithreading:
• Java provides native support for multithreading, allowing developers to create applications that
execute multiple parts of a program concurrently.

• This enhances performance and responsiveness, especially in complex applications.

High Performance:

• While often compared to C++ for performance, Java achieves high performance through the use of
highly optimized bytecode and Just-In-Time (JIT) compilation by the JVM, which translates bytecode
into native machine code at runtime.

Distributed Computing:

• Java was designed with a distributed environment in mind, facilitating the creation of applications
that can be distributed and run across networks, making it suitable for enterprise-level applications.

Rich Libraries:

• Java boasts an extensive Application Programming Interface (API) and a vast collection of standard
libraries (e.g., [Link], [Link], [Link]), providing pre-built functionalities for diverse tasks like data
manipulation, networking, and file I/O.

Simplicity:

• Java's syntax is designed to be relatively straightforward and easy to learn, especially for developers
familiar with C or C++.

• It aims to remove complex features found in other languages to enhance readability and ease of
use.

Dynamic:

• Java is dynamic, meaning it can adapt to evolving environments.

• It supports dynamic loading of classes and can be extended with new features without recompiling
the entire application.

You might also like