Professional Documents
Culture Documents
CSC 201-Lecture 2
CSC 201-Lecture 2
CSC 201-Lecture 2
Agenda
• Review of Lecture – 1
• Java program structure
• Data Types in Java
• Next Lab Session
Review Of Lecture-1
• Data
• Algorithm
• Flowchart
• Introduction to Programming
• Terms: Software, Hardware.
Structure of a Java Program
• Create a program.
• Compile a program.
– What is a compiler?
• A compiler is an application that translates source
code of a program into machine readable code.
• Run/Execute the program.
How Java Program is Compiled?
• To compile: javac <filename>.java
• To Execute: java <filename>
• When you compile a Java program, the
output is NOT exe file, but a .class file
Compiling & Executing Concepts
• JDK : Java Development Kit
• JVM : Java Virtual Machine
• JRE : Java Runtime Environment
Imperative part of Java
• Comment forms in Java
/* */ Block Comment
// Single line comment