STE-Computer-Programming-Q4 - MODULE 8

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 20

10

Computer
Programming
Quarter IV – Module 8:
Designing Computer Program on Case Study

"Designed by macrovector / Freepik"


Computer Programming – Grade 10
Self-Learning Module
First Edition, 2020

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.

Published by the Department of Education – Regional Office VIII


Regional Director: Ramir B. Uytico EdD, CESO IV
Assistant Regional Director: Arnulfo M. Balane, CESO V

Development Team of the Module


Writers: Loie April J. Paholio & Robin Andrew S. Yboa
Language Editors: Name
Content Editors: Erdenan S. Labrador
Illustrators:
Layout Artist:
Management Team:
Rosemarie M. Guino EdD, OIC – Chief, CLMD
Ryan R. Tiu EdD, EPS, CLMD – Science
Joy B. Bihag, EPS, CLMD – LRMS
Name, Chief, CID
Name, EPS, CID – Science
Name. EPS, CID - LRMS

Printed in the Philippines by ________________________

Department of Education – Regional Office VIII

Office Address: Government Center, Candahug, Palo, Leyte


Telefax: 053 - 3233156
E-mail Address: [email protected].
Introductory Message
This Self-Learning Module (SLM) is prepared so that you, our dear learners,
can continue your studies and learn while at home. Activities, questions,
directions, exercises, and discussions are carefully stated for you to understand
each lesson.

Each SLM is composed of different parts. Each part shall guide you step-by-
step as you discover and understand the lesson prepared for you.

At the end of each module, you need to answer the test to self-check your
learning. Answer keys are provided for each activity and test. We trust that you will
be honest in using these.

In addition to the material in the main text, Notes to the Teacher are also
provided to our facilitators and parents for strategies and reminders on how they
can best help you on your home-based learning.

Please use this module with care. Do not put unnecessary marks on any
part of this SLM. Use a separate sheet of paper in answering the exercises and
tests. And read the instructions carefully before performing each task.

If you have any questions in using this SLM or any difficulty in answering
the tasks in this module, do not hesitate to consult your teacher or facilitator.

Thank you.

ii
For the learner:
Welcome to the Computer Programming – Learning Module 1 on Data Types

The hand is one of the most symbolized part of the human body. It is often used to
depict skill, action, and purpose. Through our hands we may learn, create, and
accomplish. Hence, the hand in this learning resource signifies that you as a
learner is capable and empowered to successfully achieve the relevant
competencies and skills at your own pace and time. Your academic success lies in
your own hands!

This module was designed to provide you with fun and meaningful opportunities
for guided and independent learning at your own pace and time. You will be
enabled to process the contents of the learning resource while being an active
learner.

This module has the following parts and corresponding icons:

This will give you an idea of the skills or


Explore
competencies you are expected to learn in the
module. A brief drill or review to help you link
the current lesson with the previous one. The
new lesson will also be introduced to you in
various ways such as a story, a song, a poem, a
problem opener, an activity, or a situation.
This section provides a brief discussion of the
Learn
lesson. This aims to help you discover and
understand new concepts and skills.

What’s More This comprises activities for independent


practice to solidify your understanding and
skills of the topic. You may check the answers
to the exercises using the Answer Key at the
end of the module.
This includes questions or blank
Apply sentence/paragraph to be filled into process
what you learned from the lesson.

Assess This is a task which aims to evaluate your level


of mastery in achieving the learning
competency.
This contains answers to all activities in the
Answer Key module.

This contains the learner’s reflection. Learners


Reflect
are encouraged to think about the lessons
particularly the parts that went well (they have
understood) and the parts that were weak (they
have difficulty) and write about it briefly.
Learners can share their thoughts and feeling

iii
about the lessons.

At the end of this module you will also find:


References This is a list of all sources used in
developing this module.
The following are some reminders in using this module:

1. Use the module with care. Do not put unnecessary mark/s on any part of
the module. Use a separate sheet of paper in answering the exercises.
2. Read the instruction carefully before doing each task.
3. Observe honesty and integrity in doing the tasks and checking your
answers.
4. Finish the task at hand before proceeding to the next.
5. Return this module to your teacher/facilitator once you are through with it.
If you encounter any difficulty in answering the tasks in this module, do not
hesitate to consult your teacher or facilitator. Always bear in mind that you are
not alone.

We hope that through this material, you will experience meaningful learning
and gain deep understanding of the relevant competencies. You can do it!

iv
v
Explore

Introduction:

Case studies involve learners in activities of expert programmers such as


identifying decisions, justifying choices among alternatives, and evaluating the
consequences of these choices. Case studies improve computer programming
courses by emphasizing the process rather than the product of problem solving. A
case study describes a programming problem, the process used by an expert to
solve the problem, and one or more solutions to the problem.

After going through this module, you are expected to:

 Choose a case study or project.


 Design and document a program using a computer language of a
chosen case study.

Activity 1.1:
One of the special traits of Filipinos is being family-oriented and having
strong family ties. Everyone living in the house is considered a part of the family
even if he/she is not blood related. Everybody is united, and all members under the
roof help one another in doing the household chores. One basic routine in the
house is, “Washing the dishes” after a dinner.
If you are assigned as the dish washer, after a “salo-salo”, how will you
accomplish the task?
Given some situations below, arrange in sequence (based on your
experience) the steps in cleaning the dishes.

A. Place dishes on the drying rack.


B. Rinse the dishes with clean water.
C. Fill the basin with water.
D. Using the dish cloth, wash utensils one by one.
E. Add soap to the basin.
F. Scrape off leftovers from all the cutleries.
The activity above can be related in deciding a case study and designing a
computer program of it. Using any preferred computer language, you can create its
computer structure.
Learn

CASE STUDY DESIGN AND DOCUMENTATION


Case studies investigate contemporary cases for purposes of illumination and
understanding. In some instances, case studies are used to provide information for
decision making or to discover casual links in setting where cause-and-effect
relationships are complicated and not readily
Known.

The case study research design is also useful for testing whether scientific theories
and models actually work in the real world.

CASE STUDY IN COMPUTER PROGRAMMING

A case study consists of a programming problem, one or more solutions to the


problem, and a narrative description of the process used by an expert to produce
the solutions.

When to use the Case Study Research Approach?

A case study research method is appropriate when the researcher wants to answer
a descriptive question such as WHAT happened? Or an explanatory question HOW
and WHY did something happen?

Bounded System

A single entity, a unity around which there are boundaries.

https://www.slideshare.net/jlpaglinawan/all-about-case-study-types-characteristics-and-other-details

The phenomenon examined must be bounded in order to be case.


Types of Subjects of Case Study

1. Person – This type of study focuses on one particular individual. This case
study would use several types of research to determine an outcome.

2. Group – This type of study focuses on a group of people. This could be a family,
a group or friends, or even coworkers.

3. Location – This type of study focuses on a place, and how and why people use
the place.

4. Organization/Company – This type of study focuses on a business or an


organization. This could include the people who
work for the company, or an event that occurred at
the organization.

5. Event – This type of study focuses on an event, whether cultural or societal, and
how it affects those that are affected by it. An example would be the
Tylenol cyanide scandal. This event affected Johnson & Johnson, the
parent company, as well as the public at large.

3 Characteristics of Case Study

1. Particularistic - focuses on a particular situation n, event, program or


phenomenon.

2. Descriptive - the end product is a rich, thick description of the phenomenon


being studied.

3. Heuristic - the cases studied illuminate the reader's understanding of the


phenomenon under study.

- brings about the discovery of new meanings.

- extend the reader's experience.

- confirm what is already known.

Types of Case Study

1. Intrinsic Case Study

Undertaken because of researcher intrinsic interests, and aims to get deep


understanding of a certain case. The researcher focuses only on 1 problem or
concern.

2. Instrumental Case Study


An instrumental case study uses a case to gain insights into a
phenomenon. For example, a researcher interested in child obesity rates
might set up a study with middle school students and an exercise
program. In this case, the children and the exercise program are not the
focus. The focus is learning the relationship between children and
exercise, and why certain children become obese.

3. Multiple or Collective Case Study

Multiple case or collective studies use information from different studies


to formulate the case for a new study. The use of past studies allows
additional information without needing to spend more time and money
on additional studies.

Developing a Case Study

We are now in the computer age. From our homes to other entities in
our society, we are already benefiting the advantages of modern technology.
We can experience this on the electronic gadgets that we used, transactions
in banks, stores, hospitals, schools, managing transportations, data and
information processing and many more. What makes our works less
burdensome and less papers are because of the works of our technologists
and scientists. Through the development of computer systems and programs
we were able to save time, money and energy.

In developing computer software or computer program, one must


learn a programming language. From the programming language that you
have used from the previous quarters, for sure you can create one computer
software. Below is an overview on creating a program you want to develop.

Steps in developing, designing a computer program for a case study:

1. Decide a case study.


Select a case study case that is significant – a topic that you are
interested as well as your clients or audience. Work on the case study
that you are comfortable with. Plan on the flow of your case study as well
as the resources you need. Make an algorithm of it to be your guide.

2. Choosing the language


As we all know, there are many programming languages. So you
have to decide which language that is helpful and useful for your case
study. You have to consider the features and functions you need for
your project.

You can choose from the following programming languages:

1. If you want to create games, applications, drivers, operating


systems, and many other software programs, you may use
Java, Visual Basic - these two are very popular for both can
be learned easily. Added to this type programming languages
are C, C++, and C#.
2. If you want to develop online forums and services, HTML,
Python, PHP, and Perl can be your choices.

3. Deciding on an editor

Editor is a software program that allows you to create and manipulate


computer codes. It is capable of editing plain text computer files. Some of
these editors are Microsoft Visual Studio, Adobe, Eclipse, JDeveloper,
Dreamweaver or Notepad ++. These editors can make coding and testing
the code more efficient.

4. Compiler

Most computer languages are easy to understand by the creator


but difficult for a computer to understand. For a computer to read and
understand your program it must be compiled or have and interpreter.
You may need or not another program to compile or interpret it. These
are only need that they are installed on the computer or the server that is
running the script.

5. Learning the language

Once you have decided on the programming language, editor


and compiler, you are now ready to make the program. You also must
learn the syntax on how to declare variables, create conditional
statements, perform the loops, understand the escape sequences, make
comments, or temporarily disable parts of the code, understand regular
expressions.

Sample Case Study.


Case Study: Odd and Even Integer Checker Java Language
Algorithm:

https://www.javaguicodexample.com/
javaprogramexampleusejgrasp1.html

Computer source code/syntax:


import java.util.Scanner;

publicclass OddEvenNumber
{
public static void main(String[] args)
{
int num, remainder;

Scanner readinput = new Scanner


(System.in);
// read and store input from user
System.out.print ("Enter an integer: ");
num = readinput.nextInt();
// find the remainder
remainder = num % 2;
// test remainder for odd or even
if(remainder == 0)
System.out.println(num + " is an even
number.");
else
System.out.println(num + " is an odd
number.");
}
}

An output samples:

Enter an integer: 100


100 is an even number.

Enter an integer: -13


-13 is an odd number.

Enter an integer: 51
51 is an odd number.

Enter an integer: 0
0 is an even number.

Engage

Activity 3.1:

Instruction: Below are the steps in withdrawing money from the bank
through ATM machine.
1. Formulate a case study of the given sample.
2. Make a flowchart or algorithm as you cut the figures on the left and
paste in on the right according to the process of withdrawing through
ATM or you may write your answers after the number corresponding
the steps.
3. Make a source code using any language.

Take the 1.
card

2.

Enter PIN
3.
Insert Card
4.

Start

5.

End

6.
Enter
Withdrawal
Amount
7.

Select
Language
8.

Take the
printed
receipt. 9.

Get the cash 10.

Select Type of 11.


Account - Savings

Apply

Activity 4.1:
INSTRUCTION:
1. Conduct a case study. Provide its title. You can use your case
study as a tool of your Research II subject. Indicate the
programming language that you will use.
2. Make a flowchart or algorithm.
3. Develop a source code or program.
4. Document all your works and activities.

Assess

Multiple Choice. Choose the letter of the best answer. Write the chosen letter on a
separate sheet of paper.
1. Which of the following does not describe a case study?
a. programming problem
b. one or more solutions to the problem.
c. used in transacting business
d. the process used by an expert to solve the problem

2. __________ runs through the program and translates the whole of it into machine
code at once for the computer to understand.
a. Translator
b. Compiler
c. Interpreter
d. Converter

3. A case study should answer the following questions, except______


a. Why
b. How
c. What
d. Who

4. The following are used to develop online forums and services except________
a. C++
b. Python
c. PHP
d. Perl

5. Which case study uses a case to gain insights into a phenomenon?


a. Intrinsic Case Study
b. Instrumental Case Study
c. Multiple Case Study
d. Collective Case

6. ________ describes the characteristics as the cases studied illuminate the


reader's understanding of the phenomenon under study.
a. Particularistic
b. Descriptive
c. Complex
d. Heuristic

7. Which of the following does not belong to the group?


a. Decide a case study.
b. Learning the computer language
c. Bugging the codes
d. Deciding on an editor

8. This type of study focuses on an incident, whether cultural or societal, and how
it affects those that are affected by it. What is this?
a. Event
b. People
c. Group
d. Location

9. The following are editors except_______,


a. Microsoft Visual Studio,
b. Microsoft Word
c. Eclipse
d. JDeveloper

10. When making the program, the following should be considered, except________.
a. learn the syntax on how to declare variables
b. create conditional statements
c. perform the loops
d. disregard the expressions
Reflect

Reflection guide questions / statement.


1. How useful is computer programming?
2. What if computer programming was not introduce to the
world?
3. Can you see yourself seven(7) years from now in the world of
computer science? If yes, In what way? If not, why not?
Answer Key

Explore ASSESSMENT

F, C, E, D, B, A 1. c

2. b

3. d
ENGAGE
4. a
Answers may vary on the programming
5. b
language used.
6. d

APPLY 7. c

8. a
Answers may vary on the programming
language used. 9. b

10. d
References

https://people.eecs.berkeley.edu/~clancy/classroom.html#:~:text=Case
%20studies%20involve%20learners%20in,the%20product%20of%20problem
%20solving.
http://2012books.lardbucket.org/books/sociological-inquiryprinciples-
qualitative-and-quantitative-methods/s13-01-fieldresearch-what-is-it-
and-.html
https://people.eecs.berkeley.edu/~clancy/web/case.studies.html
https://www.universalclass.com/articles/business/case-studies-
types.htm#:~:text=An%20intrinsic%20case%20study%20is,Genie%20is
%20the%20topic.
https://www.computerhope.com/issues/ch000675.htm#:~:text=An
%20editor%20is%20any%20program,can%20get%20started%20for%20free.
https://www.javaguicodexample.com/javaprogramexampleusejgrasp1.html

You might also like