LP 1 - Introduction to Java
LP 1 - Introduction to Java
b. Performance Standard The learner shall be able to independently create/provide quality and
marketable products and/ or services in Programming (Java), prescribed by
TESDA Training Regulations.
c. Learning Competencies
A. References:
b. Learner’s Material K11 Module: Basic Animation, Course Outline, Course Syllabus, and
Curriculum guide
B. Activity List of Learning Resources for pictures, ICT Integration-Multimedia (CANVA App/ Microsoft
Development Engagement Activities PowerPoint Presentation), Google Meet, and LMS
IV: Procedures:
● A development environment.
- As a development environment, Java technology provides you
with a large suite of tools:
▪ A compiler
▪ An interpreter
▪ A document generator
▪ A class file packaging tool and so on…
JAVA FEATURES
C++ Style Comment starts with // and all the text after this is treated as
comments.
Example: // This is a C++ style or single line comments
2. You should indent the next statements after the start of a block. For
example:
PROGRAM CODES:
DISSECTING THE FIRST PROGRAM
● Line number 1 is the package statement; it tells the package where the
program is located. In this example, program1 is located on the package
Programming2. A package in Java is used to group related
classes/programs, Think of it as a folder in a file directory.
● Line number 2 indicates the name of the class which is Prog1. In Java, all
code should be placed inside a class declaration. The class uses an access
specifier public, which indicates that our class is accessible to other
classes from other packages (packages are a collection of classes).
● Line number 3 - 5 indicates a Java comment (Multi-Line Comment).
● Line number 6 indicates the name of one method in Prog1 which is the
main method. The main method is the starting point of a Java program.
All programs except Applets written in Java start with the main method.
● Line number 7 indicates a comment (Single Line Comment).
● Line number 8 is a statement (System.out.println()) that prints the text
enclosed by quotation on the screen.
● Line number 9 - 10 are closing braces for the main method (Line 6) and
class name (Line 2) respectively.
d. Engagement After the discussion, the student will answer the following questions.
1. What is block?
2. What is a comment?
3. What is a statement?
e. Assimilation Formative Test:
Direction: Using the databank below, identify the following items and write your
answer in the space provided before each item.
DATA BANK:
Ms. Pamela Anne D. Gorospe Ms. Patty Mae R. Lim Mr. Jemel Gary A. Gepiga
Subject Teacher Subject Coordinator Academic Coordinator
Noted by: