HDTutorial
EN

Playback starts YouTube’s embedded player (privacy-enhanced mode).

How To Compile And Run Java Program In Ubuntu Linux

44,122 views November 2, 2017 3:22

Watch on YouTube
ChannelDevTech Solutions

Description from the creator

In this quick tutorial, learn step-by-step how to compile Java source code into bytecode (.class files) and run it using the command line on both Ubuntu Linux and Windows!

Whether you are using OpenJDK on Linux or CMD on Windows, this beginner-friendly guide breaks down the essential commands you need to know.

📌 What You'll Learn:

Navigating to your file directory using the terminal/cmd

Compiling .java files into .class bytecode using javac

Executing compiled Java programs using java

Essential tips to avoid common beginner errors (like file naming and extensions)

⚙️ Commands Used in This Video:

Open Terminal (Linux): Ctrl + Alt + T

Open Command Prompt (Windows): Win + R then type cmd

Navigate directory: cd path/to/folder

Compile code: javac filename.java

Run program: java ClassName

💡 Prerequisites:
Make sure you have Java Development Kit (JDK) installed on your system before following along.

🔔 Don't forget to Like, Share, and Subscribe for more Java and programming tutorials!

#Java #Programming #Terminal #Linux #Windows #JavaTutorial #OpenJDK #CommandLine

About this tutorial

DevTech Solutions published this 3:22 video tutorial on November 2, 2017. It has been watched 44,122 times on YouTube.

Category
Education
Duration
3:22
Published
November 2, 2017
Views
44,122
Likes
416

Tags

Share

This tutorial in other languages