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

Week 2 Q 2 Programming

The document provides a learning activity worksheet for students on nested if statements. It contains questions to test students' understanding of conditional expressions, relational operators, if-else statements, and nested if statements. It also includes activities for students to write if statements based on different scenarios and design a flowchart to categorize auditorium seats by number.

Uploaded by

Felicity Sanchez
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 views4 pages

Week 2 Q 2 Programming

The document provides a learning activity worksheet for students on nested if statements. It contains questions to test students' understanding of conditional expressions, relational operators, if-else statements, and nested if statements. It also includes activities for students to write if statements based on different scenarios and design a flowchart to categorize auditorium seats by number.

Uploaded by

Felicity Sanchez
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/ 4

Republic of the Philippines

Department of Education

Learning Activity Worksheets (LAW)


PROGRAMMING NCIII
Grade 12
NAME: ________________________________________________ SCORE: _______________
GRADE & SECTION: _____________________________________ TEACHER: _____________

NESTED IF STATEMENTS
Week 2

ACTIVITY 1 Identification. (10 points)


Directions: Read each item carefully and identify concept/terms on every item. Write
your answers on the space provided.
1. What type of expression is either true or false?

2. What operators determine whether a specific relationship exists between two


values?

3. What decision construct is used to decide among three or more actions?

4. What decision construct occurs when the true or false statement of an if


statement is itself an if statement?

5. What term is used to describe enclosing one structure inside of another?


LEARNING ACTIVITY WORKSHEETS
Grade 12 – Programming NC III
ACTIVITY 2 Write an IF Statement. (10 points)
Directions: Write the following IF statements. Write your answers on the space
provided.

1. Write an if statement to check whether the variable x is equal to y.

2. Write an if-else statement that assigns 0 to x when y is equal to 10. Otherwise, it


should assign 1 to x.

3. Write an if-else statement that sets wage per day of 400 for an employee who
has work hours less than or equal to 40, otherwise, wage per day is set to 450.

4. Write an if statement that sets the variable rate to 400 if the boolean variable
over is false.

5. Write an if statement that displays the message “invalid number” if the value is
less than 1. Otherwise, assign 200 to variable num.

Q2 - Week 2
MELC: Demonstrate using Decision constructs in accordance with Java framework.
TLE_ICTJAVA11-12POAD-IIf-i-29
(Government Property. Not for sale)

Page 2 of 4
LEARNING ACTIVITY WORKSHEETS
Grade 12 – Programming NC III
ACTIVITY 3 General Format. (10 points)
Directions: Write the general format of an If-Else-If construct and draw the equivalent
flowchart. Write your answers on the space provided.

Q2 - Week 2
MELC: Demonstrate using Decision constructs in accordance with Java framework.
TLE_ICTJAVA11-12POAD-IIf-i-29
(Government Property. Not for sale)

Page 3 of 4
LEARNING ACTIVITY WORKSHEETS
Grade 12 – Programming NC III
ACTIVITY 4 Algorithm. (10 points)
Directions: Design a flowchart that assigns category to the seats in an
auditorium, depending on the seat number. Write your answers on the space provided.

Seat Number Category


101 and above Platinum
51-100 Gold
1-50 Silver
Below 1 Invalid

GABRIEL JOSEPH T. BALIUAG


TIII/LPCNSHS – Dona Josefa Campus

Q2 - Week 2
MELC: Demonstrate using Decision constructs in accordance with Java framework.
TLE_ICTJAVA11-12POAD-IIf-i-29
(Government Property. Not for sale)

Page 4 of 4

You might also like