Revision UPS 1
Revision UPS 1
2022/2023
1.0 Introduction to
Programming
Types of Programming Language
1. ?
2. ?
Types of Programming Language
(a)Low level language (b) Low level language (c) High level language
Types of Programming Language Paradigm
1. ?
2. ?
3. ?
Types of Programming Language Paradigm
1. Procedural Programming
2. Object-oriented Programming
3. Logic Programming
2.0 Approach in
Problem Solving
Steps in Problem Solving
1. ?
2. ?
3. ?
4. ?
5. ?
Steps in Problem Solving
Before developing the system:
1. Problem analysis *analyse the requirements of the problem
4. Testing *to ensure the program runs correctly and is error free
1. ?
2. ?
Two types of algorithm
1. Pseudocode
2. Flowchart
Two types of algorithm
(a) (b)
Two types of algorithm
1. ?
2. ?
3. ?
4. ?
Importance of Algorithm
1. ?
2. ?
3. ?
Types of Control Structure
1. Sequence
2. Selection
3. Repetition
Exercise
2. Identify the suitable type of control structure given in TABLE 1. [3 marks]
No Algorithm Control Structure
(a)
(b) Start
Read cent
ringgit = cent x 0.01
Print ringgit
Stop
(c)
25
Exercise
2. Identify the suitable type of control structure given in TABLE 1. [3 marks]
No Algorithm Control Structure
(a)
Selection
(b) Start
Read cent
ringgit = cent x 0.01
Print ringgit Sequence
Stop
(c)
Repetition
26
Sequence
Selection
Repetition
Flowchart Symbols- Name & Descriptions
for each control structure
4.1 Introduction to Java
Program
Structure of OOP consists of:
1. ?
2. ?
3. ?
Structure of OOP consists of:
1. Class
2. Object
3. Method
Structure of OOP consists of:
1. Class
- Class is a description of the properties (states) and the behaviors
(functionality) of one or more objects
Structure of OOP consists of:
2. Object
- entity that has both state and behavior.
Structure of OOP consists of:
3. Method
- Method is a collection of statements that perform some specific
tasks and return the result to the caller.