SlideShare ist ein Scribd-Unternehmen logo
1 von 1
Downloaden Sie, um offline zu lesen
Obtaining the Java Development Kit
Now that the theoretical underpinning of Java has been explained, it is time to start writing
Java programs. Before you can compile and run those programs, however, you must have a Java
development system installed on your computer. The one used by this book is the standard
JDK (Java Development Kit), which is available from Sun Microsystems. Several other Java
development packages are available from other companies, but we will be using the JDK
because it is available to all readers. It also constitutes the final authority on what is and isn’t
proper Java. At the time of this writing, the current release of the JDK is the Java 2 Platform
Standard Edition version 5 (J2SE 5). Because J2SE 5 contains many new features that are not
supported by earlier versions of Java, it is necessary to use J2SE 5 (or later) to compile and run
the programs in this book.
The JDK can be downloaded free of charge from www.java.sun.com. Just go to the
download page and follow the instructions for the type of computer that you have. After you
have installed the JDK, you will be ready to compile and run programs. The JDK supplies two
primary programs. The first is javac.exe, which is the Java compiler. The second is java.exe,
which is the standard Java interpreter, and is also referred to as the application launcher.
One other point: the JDK runs in the command prompt environment. It is not a windowed
application.
CRITICAL SKILL


1.6 A First Simple Program
Let’s start by compiling and running the short sample program shown here.
/*
This is a simple Java program.
Call this file Example.java.
*/
class Example {
// A Java program begins with a call to main().
public static void main(String args[]) {
System.out.println("Java drives the Web.");
}
}
You will follow these three steps:
1. Enter the program.
2. Compile the program.
3. Run the program.

Weitere ähnliche Inhalte

Was ist angesagt?

Lecture android best practices
Lecture   android best practicesLecture   android best practices
Lecture android best practices
eleksdev
 
Java Development EcoSystem
Java Development EcoSystemJava Development EcoSystem
Java Development EcoSystem
Alex Tumanoff
 
Maven TestNg frame work (1) (1)
Maven TestNg frame work (1) (1)Maven TestNg frame work (1) (1)
Maven TestNg frame work (1) (1)
QA Programmer
 

Was ist angesagt? (20)

Setup Build & Deploy with Jenkins CI
Setup Build & Deploy with Jenkins CISetup Build & Deploy with Jenkins CI
Setup Build & Deploy with Jenkins CI
 
Lecture android best practices
Lecture   android best practicesLecture   android best practices
Lecture android best practices
 
Best java courses in navi mumbai best classes for java in navi mumbai-java cl...
Best java courses in navi mumbai best classes for java in navi mumbai-java cl...Best java courses in navi mumbai best classes for java in navi mumbai-java cl...
Best java courses in navi mumbai best classes for java in navi mumbai-java cl...
 
Quality Assurance using the Eclipse IDE
Quality Assurance using the Eclipse IDEQuality Assurance using the Eclipse IDE
Quality Assurance using the Eclipse IDE
 
Selenium using C# by Yogesh Kumar
Selenium using C# by  Yogesh KumarSelenium using C# by  Yogesh Kumar
Selenium using C# by Yogesh Kumar
 
App c
App cApp c
App c
 
Jenkins
JenkinsJenkins
Jenkins
 
Extending NetBeans IDE
Extending NetBeans IDEExtending NetBeans IDE
Extending NetBeans IDE
 
Vsts ci cd-java
Vsts ci cd-javaVsts ci cd-java
Vsts ci cd-java
 
Java Development EcoSystem
Java Development EcoSystemJava Development EcoSystem
Java Development EcoSystem
 
Continuous integration with Jenkins
Continuous integration with JenkinsContinuous integration with Jenkins
Continuous integration with Jenkins
 
Core java environment setup and details
Core java environment setup and detailsCore java environment setup and details
Core java environment setup and details
 
java new technology
java new technologyjava new technology
java new technology
 
Gradle
GradleGradle
Gradle
 
Chapter 1 java
Chapter 1 java Chapter 1 java
Chapter 1 java
 
Ci jenkins maven svn
Ci jenkins maven svnCi jenkins maven svn
Ci jenkins maven svn
 
Android Architecture Components
Android Architecture ComponentsAndroid Architecture Components
Android Architecture Components
 
Java projectfinal
Java projectfinalJava projectfinal
Java projectfinal
 
Maven TestNg frame work (1) (1)
Maven TestNg frame work (1) (1)Maven TestNg frame work (1) (1)
Maven TestNg frame work (1) (1)
 
What's new in Eclipse Mars
What's new in Eclipse MarsWhat's new in Eclipse Mars
What's new in Eclipse Mars
 

Ähnlich wie simple Java Hello

22412_1_1_1_P_603c5bf161f61_File.pdf
22412_1_1_1_P_603c5bf161f61_File.pdf22412_1_1_1_P_603c5bf161f61_File.pdf
22412_1_1_1_P_603c5bf161f61_File.pdf
NileshWadhave1
 
Java Semimar Slide (Cetpa)
Java Semimar Slide (Cetpa)Java Semimar Slide (Cetpa)
Java Semimar Slide (Cetpa)
Pratima Parida
 
Java Semimar Slide (Cetpa)
Java Semimar Slide (Cetpa)Java Semimar Slide (Cetpa)
Java Semimar Slide (Cetpa)
Pratima Parida
 

Ähnlich wie simple Java Hello (20)

Java part 1
Java part 1Java part 1
Java part 1
 
1 about eclipse
1 about eclipse1 about eclipse
1 about eclipse
 
1 about eclipse
1 about eclipse1 about eclipse
1 about eclipse
 
Introduction to java technology
Introduction to java technologyIntroduction to java technology
Introduction to java technology
 
1 about eclipse
1 about eclipse1 about eclipse
1 about eclipse
 
Hello World Program in Java .pdf
Hello World Program in Java .pdfHello World Program in Java .pdf
Hello World Program in Java .pdf
 
Class 1
Class 1Class 1
Class 1
 
Introduction to java programming tutorial
Introduction to java programming   tutorialIntroduction to java programming   tutorial
Introduction to java programming tutorial
 
Learn java in one day and learn it well 2016 jamie chan
Learn java in one day and learn it well 2016   jamie chanLearn java in one day and learn it well 2016   jamie chan
Learn java in one day and learn it well 2016 jamie chan
 
Setting Up Java Environment | PDF
Setting Up Java Environment | PDFSetting Up Java Environment | PDF
Setting Up Java Environment | PDF
 
J introtojava1-pdf
J introtojava1-pdfJ introtojava1-pdf
J introtojava1-pdf
 
22412_1_1_1_P_603c5bf161f61_File.pdf
22412_1_1_1_P_603c5bf161f61_File.pdf22412_1_1_1_P_603c5bf161f61_File.pdf
22412_1_1_1_P_603c5bf161f61_File.pdf
 
JRE , JDK and platform independent nature of JAVA
JRE , JDK and platform independent nature of JAVAJRE , JDK and platform independent nature of JAVA
JRE , JDK and platform independent nature of JAVA
 
JAVA CORE
JAVA COREJAVA CORE
JAVA CORE
 
CORE JAVA
CORE JAVACORE JAVA
CORE JAVA
 
Introduction to java
Introduction to javaIntroduction to java
Introduction to java
 
Basic difference between jdk,jre,jvm in advance java course
Basic difference between jdk,jre,jvm in advance java courseBasic difference between jdk,jre,jvm in advance java course
Basic difference between jdk,jre,jvm in advance java course
 
JAVA First Day
JAVA First DayJAVA First Day
JAVA First Day
 
Java Semimar Slide (Cetpa)
Java Semimar Slide (Cetpa)Java Semimar Slide (Cetpa)
Java Semimar Slide (Cetpa)
 
Java Semimar Slide (Cetpa)
Java Semimar Slide (Cetpa)Java Semimar Slide (Cetpa)
Java Semimar Slide (Cetpa)
 

Kürzlich hochgeladen

Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please Practise
AnaAcapella
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
ciinovamais
 
The basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptxThe basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptx
heathfieldcps1
 

Kürzlich hochgeladen (20)

Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please Practise
 
SOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning PresentationSOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning Presentation
 
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...Kodo Millet  PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
Kodo Millet PPT made by Ghanshyam bairwa college of Agriculture kumher bhara...
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
Unit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxUnit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptx
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and Modifications
 
Dyslexia AI Workshop for Slideshare.pptx
Dyslexia AI Workshop for Slideshare.pptxDyslexia AI Workshop for Slideshare.pptx
Dyslexia AI Workshop for Slideshare.pptx
 
Sociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning ExhibitSociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning Exhibit
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdf
 
The basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptxThe basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptx
 
How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17
 
Making communications land - Are they received and understood as intended? we...
Making communications land - Are they received and understood as intended? we...Making communications land - Are they received and understood as intended? we...
Making communications land - Are they received and understood as intended? we...
 
Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)
 
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17  How to Extend Models Using Mixin ClassesMixin Classes in Odoo 17  How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
 
ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701
 
How to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POSHow to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POS
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
Food safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdfFood safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdf
 
General Principles of Intellectual Property: Concepts of Intellectual Proper...
General Principles of Intellectual Property: Concepts of Intellectual  Proper...General Principles of Intellectual Property: Concepts of Intellectual  Proper...
General Principles of Intellectual Property: Concepts of Intellectual Proper...
 

simple Java Hello

  • 1. Obtaining the Java Development Kit Now that the theoretical underpinning of Java has been explained, it is time to start writing Java programs. Before you can compile and run those programs, however, you must have a Java development system installed on your computer. The one used by this book is the standard JDK (Java Development Kit), which is available from Sun Microsystems. Several other Java development packages are available from other companies, but we will be using the JDK because it is available to all readers. It also constitutes the final authority on what is and isn’t proper Java. At the time of this writing, the current release of the JDK is the Java 2 Platform Standard Edition version 5 (J2SE 5). Because J2SE 5 contains many new features that are not supported by earlier versions of Java, it is necessary to use J2SE 5 (or later) to compile and run the programs in this book. The JDK can be downloaded free of charge from www.java.sun.com. Just go to the download page and follow the instructions for the type of computer that you have. After you have installed the JDK, you will be ready to compile and run programs. The JDK supplies two primary programs. The first is javac.exe, which is the Java compiler. The second is java.exe, which is the standard Java interpreter, and is also referred to as the application launcher. One other point: the JDK runs in the command prompt environment. It is not a windowed application. CRITICAL SKILL 1.6 A First Simple Program Let’s start by compiling and running the short sample program shown here. /* This is a simple Java program. Call this file Example.java. */ class Example { // A Java program begins with a call to main(). public static void main(String args[]) { System.out.println("Java drives the Web."); } } You will follow these three steps: 1. Enter the program. 2. Compile the program. 3. Run the program.