ObjectivesOn completion of this period, you would be able to know•   The process of entering and execution of a Java    pr...
Recap•   What is a Byte Code•   What are the OOP Concepts•   Define Encapsulation•   Define Inheritance•   Define Polymorp...
The Process of Entering and Executing a Java                 Program  Entering a Java Program  •   We can create a program...
The Process of Entering and Executing a Java                                           Contd..                    Programc...
The Process of Entering and Executing a Java                                       Contd..                 Program  •   We...
The Process of Entering and Executing a Java                                                 Contd..                      ...
Executing a Java ProgramExecuting a Java Program involves two steps1) Compiling a Java program2) Running a Java program   ...
Compiling a Java Program•   To compile the program we must run with the    Java compiler ‘javac’ with the name of the sour...
Executing a Java Program•   We need to use the Java interpreter to run a    stand alone program•   At the command prompt t...
Summary•   The process of entering and execution of a Java    program•   White spaces, separators, literals and keywords• ...
Quiz1. Period . is a _________a)   Key Wordsb)   White Spacec)   Separatord)   Comment                     9CM604.5   11
Frequently Asked Questions•   Explain the process of entering and executing a    Java program•   Explain the separators in...
Upcoming SlideShare
Loading in …5
×

Process program9 cm604.5

226 views

Published on

0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
226
On SlideShare
0
From Embeds
0
Number of Embeds
15
Actions
Shares
0
Downloads
4
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Process program9 cm604.5

  1. 1. ObjectivesOn completion of this period, you would be able to know• The process of entering and execution of a Java program• White spaces, separators, literals and keywords• Comments in Java 9CM604.5 1
  2. 2. Recap• What is a Byte Code• What are the OOP Concepts• Define Encapsulation• Define Inheritance• Define Polymorphism 9CM604.5 2
  3. 3. The Process of Entering and Executing a Java Program Entering a Java Program • We can create a program using any text editor • Let us assume we have entered the following program 9CM604.5 3
  4. 4. The Process of Entering and Executing a Java Contd.. Programclass Example{ public static void main(String args[]) { system.out.println(“Hello World”); }} 9CM604.5 4
  5. 5. The Process of Entering and Executing a Java Contd.. Program • We must save this program in a file called Example.java • Ensure that the file name contains the class name • This file is called the source file 9CM604.5 5
  6. 6. The Process of Entering and Executing a Java Contd.. Program• All Java source files will have the extension .java• If a program contains multiple classes, the file name must be the class name of the class containing the main method 9CM604.5 6
  7. 7. Executing a Java ProgramExecuting a Java Program involves two steps1) Compiling a Java program2) Running a Java program 9CM604.5 7
  8. 8. Compiling a Java Program• To compile the program we must run with the Java compiler ‘javac’ with the name of the source file on the command line shown below C: javac Example.java 9CM604.5 8
  9. 9. Executing a Java Program• We need to use the Java interpreter to run a stand alone program• At the command prompt type C: java Example 9CM604.5 9
  10. 10. Summary• The process of entering and execution of a Java program• White spaces, separators, literals and keywords• Comment statements in Java 9CM604.5 10
  11. 11. Quiz1. Period . is a _________a) Key Wordsb) White Spacec) Separatord) Comment 9CM604.5 11
  12. 12. Frequently Asked Questions• Explain the process of entering and executing a Java program• Explain the separators in Java• Write about white spaces in Java• List any eight keywords in Java• How can you write comments in Java 9CM604.5 12

×