0% found this document useful (0 votes)
23 views14 pages

Las Ict7 Java Q3 Las 1

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
23 views14 pages

Las Ict7 Java Q3 Las 1

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

9

Schools Division of Koronadal City

JUNIOR HIGH SCHOOL


ICT 7 – Java
Learning Activity Sheet 1:
Conditional Statements

QUARTER 3 WEEK 1
Learning Activity Sheet
Quarter 3 – Activity Sheet 1: Conditional Statements
Unang Edisyon, 2023

Republic Act 8293, section 176 states that: No copyright shall subsist in any work of the
Government of the Philippines. However, prior approval of the government agency or
office wherein the work is created shall be necessary for exploitation of such work for
profit. Such agency or office may, among other things, impose as a condition the payment
of royalties.

Borrowed materials (i.e., songs, stories, poems, pictures, photos, brand names,
trademarks, etc.) included in this module are owned by their respective copyright holders.
Every effort has been exerted to locate and seek permission to use these materials from
their respective copyright owners. The publisher and authors do not represent nor claim
ownership over them.

Inilathala ng Kagawaran ng Edukasyon


Kalihim: Leonor Magtolis Briones
Pangalawang Kalihim: Diosdado M. San Antonio

Learning Activity Sheet Development Team

Writers: Arnold John B. De Vera, James Aldrin S. Estabillo and


Editor: Name
Reviewers: Evelyn C. Frusa PhD, Grace J. Miravalles, Rolex H. Lotilla and Arvin M.
Tejada
Illustrator: Name
Layout Artist: Name
Management Team: Crispin A. Soliven Jr, CESE - Schools Division Superintendent
Levi Butihin - Asst. Schools Division Superintendent
Prima Roullo - CID Chief
Grace J. Miravalles - EPS, EPP/TLE
Evelyn C. Frusa, PhD - Division EPS In Charge of LRMS
Bernardita M. Villano - Division ADM Coordinator
Inilimbag sa Pilipinas ng ________________________

Department of Education – Region XII – Koronadal City Division


Office Address: ____________________________________________
____________________________________________
Telefax: ____________________________________________
E-mail Address: ____________________________________________
9

The Java Program


(TLE_ICTJAVA1 1-12POAD-IIf-i-29)
Specific Objective/s

This Learning Activity Module (LAS) was designed and written with you in mind. It is
here to help you master Java Technology and the Java Programming Language. The
scope of this module permits it to be used in many different learning situations. The
language used recognizes the diverse vocabulary level of students. The lessons are
arranged to follow the standard sequence of the course. But the order in which you
read them can be changed to correspond with the textbook you are now using.
The LAS is divided into one (1) learning outcome, specifically:

• LO1 - Demonstrate knowledge of Java technology and Java


programming;
o 1.5 Demonstrate using Operators and Decision Constructs in
accordance with Java framework
After going through this Learning Activity Sheets, you are expected to:
1. Analyze patterns of programming in Java Programming Language;
2. Write simple Java Programs;
3. Compile and execute Java Programs;
4. Compile Java Programs using BlueJ;
5. Execute Java Programs using BlueJ;
6. Debug Java Programs;
7. Recognize problems that can be solved using conditional statements.;
and
8. Create and debug programs using if-else.
Directions/Instructions

In this Learning Activity Sheet, you will study about Java technology and
Java programming.

Notes to the Students

1. Study the lessons and answer religiously the activities. These will guide you on
what you will learn at the end of this Learning Activity Sheet.

2. Discover what you already know by answering the learning activities.

3. Apply what you have learned in real-life situation.


Activity

Activity 1:

Directions: There are two pictures in each item, Picture A in column A and
another Picture B in column B. Write the A if you like picture A more than
Picture B. Otherwise, write B if you prefer Picture B more than Picture A. Write
your answer on the Space Provided.

COLUMN A COLUMN B Your Answer

tablish process charted. boundaies - the


Procedure

If Statement

If the condition in the if statement is true, the succeeding statement will be


executed.

Syntax:

if (<boolean condition>) {

<statement/s>

Example:

If-Else Statement

If the if expression evaluates to false, the statements within the scope of the else
part will be run.

Syntax:

if (<boolean condition>) {

<statement/s>

}else{

<statement/s>

Example:
Nested If Statements

When you want to evaluate several conditions, use the nested-if structure.

Example:

Switch Statements

The switch statement can be an alternative to the nested-if statement because in


the switch statement, you are also allowed to have several options.

Example:
? Questions
Activity 2:

Directions: Read and analyze the given Java Program below. Identify the objective
or what each conditional statements was trying to solve or achieve in the code
marked by a comment that indicates item number. Then write the expected output
for each item. Write your answers on the space provided below.

Item # Objective or Purpose Expected output


1
2
3
4
5
Activity 3

Directions: Identify the output asked in each item based on the Java Code given in
Activity 2. Write only the output affected in each item. Write your answer on the
given spaces.

_____________________ 1. What will be the 1st line of output if number is 8?


_____________________ 2. What will be the 2nd line of output if number is 8?
_____________________ 3. What message will be shown if age is 25?
_____________________ 4. What message will be shown if age is 2?
_____________________ 5. If both x and y are -3, what will the program
print?
_____________________ 6. If x is -1 and y is 4, what will the program print?
_____________________ 7. What will be the output if the age is -12?
_____________________ 8. What is the output if grade is ‘0’?
_____________________ 9. What message will be shown if the grade is ‘B’?
_____________________ 10. What will be the 2nd line of output if number is
-12?

Activity 4.

Directions: Write a Java Conditional Statement determine if the value of variable


assigned to variable num is divisible by 3. Write your code in the box including the
variable declaration of num and your chosen number.
Rubrics for scoring
Category 5 points 1 Point No Points
Accuracy and Code is Code is Attempt to
reliability logically incorrect. answer or No
correct, error answer.
free, and
expected to
provide
correct
output.
Closure

What I have learned in this activity?

1. I have learned that_________________________________________________________


__________________________________________________________________________________
__________________________________________________________________________________
__________________________________________________________________________________
__________________________________________________________________________________
__________________________________________________________________________________
__________________________________________________________________________________

2. I need to know more about_________________________________________________


__________________________________________________________________________________
__________________________________________________________________________________
__________________________________________________________________________________
__________________________________________________________________________________
__________________________________________________________________________________
__________________________________________________________________________________
References

RAMILO, R. V., & PASCO, D. M. (n.d.). COMPUTER HARDWARE SERVICING. K TO


12 - TECHNOLOGY AND LIVELIHOOD EDUCATION.
Blanco, E. (2017, September 12). CSS NC II learning Module. Retrieved June 03,
2020, from https://www.slideshare.net/edmundblanco/css-nc-ii-learningmodule
K to 12 Basic Education Curriculum Technology Livelihood Education Learning
module -Computer hardware servicing
https://kupdf.net/download/common-tools-and-equipment-for-computersystem-
servicing_5a2f023ce2b6f5f679a8c411_pdf
Department of Education, Soccsksargen Region. TLE CSS Quarter 1 Module 5:
Preparing and Interpreting Technical Drawing.
De Jesus Jr. J., et al. (2012). Programming and Databases 2 nd Edition. TechFactors
Inc.
Para sa mga katanungan o puna, sumulat o tumawag sa:

Department of Education – Koronadal City Division

-------------------------------------
-------------------------------------
-------------------------------------

Telefax: -------------------------

Email Address: ------------------------------------


PAHATID – LIHAM

You might also like