JavaSetup

Java Setup

If you’re new to programming and want to learn Java, the first thing you need to do is set up Java on your computer. Don’t worry — it’s simple! Just follow these steps.

What is JDK and Why Do You Need It?

JDK stands for Java Development Kit. It’s a package that includes everything you need to write and run Java programs. Without it, your computer won’t understand Java code.

Step-by-Step Installation Guide
Step 1 — Download JDK
  1. Go to Google and search "Download JDK Oracle".

  2. Click on the official Oracle link.

  3. Choose the version that matches your operating system (Windows, macOS, or Linux).

  4. Download the installer file.

Step 2 — Install JDK
  1. Open the downloaded file.

  2. Click "Next" through the setup steps.

  3. Finish the installation.

Step 3 — Set Environment Variables (Windows only)
  1. Right-click on "This PC" → click "Properties".

  2. Go to "Advanced system settings" → click "Environment Variables".

  3. Under "System Variables", find Path and click "Edit".

  4. Add the JDK bin folder path at the end (your folder name might be different depending on the version).

Path entry to add

Text
C:\Program Files\Java\jdk-22\in
Step 4 — Check if Java is Installed Correctly

Open Command Prompt and run:

Bash
java -version

If installed properly, it will show the version of Java.

What’s Next?

Now that Java is installed, you’re ready to write your first program! You can use a simple text editor like Notepad, or install an IDE like IntelliJ IDEA or Eclipse to make coding easier.