BIC 10204 Chapter 1 Introduction To Computer Programming
BIC 10204 Chapter 1 Introduction To Computer Programming
Introduction to Computer
Chap 1
Programming
history of computing
computer programming languages
components of programming
Phases of software development lifecycle
1
Introduction to Computer
Chap 1
Programming
Accept data
Process data according to specific rules
Produce results
Store results for future use
3
Introduction to Computer
Chap 1
Programming
2
Introduction to Computer
Chap 1
Programming
What?
Why?
How? When?
Introduction to Computer
Chap 1
Programming
Programmer
6
3
Introduction to Computer
Chap 1
Programming
Introduction to Computer
Chap 1
Programming
An example of a computer
program or software
written in C programming
language
4
Introduction to Computer
Chap 1
Programming
A series of instructions
that tells a computer
what to do and how to do
a task.
Introduction to Computer
Chap 1
Programming
What ?
Also known as
any sequence of statements code snippet or
and/or declarations written program code
in some human-readable
computer programming
language.
One part of the whole
computer program.
10
5
Introduction to Computer
Chap 1
Programming
#include <stdio.h>
int first,second;
void addition(int x,int y);
void main()
{
printf("Enter first number:");
scanf("%d",&first); Source code
printf("Enter second number:");
scanf("%d",&second);
}
11
Introduction to Computer
Chap 1
Programming
?
What ?
Computer Programming
How to program ?
Requires knowledge in the application domain
Follow the steps in software development method
12
6
Introduction to Computer
Chap 1
Programming
Programming is a problem-
solving activity
To solve the problems
occurred in life with
the assistance of
computer To help improve daily process
e.g: transaction,
payroll,accounting, registration,
information exchange etc.
13
Introduction to Computer
Chap 1
Programming
?
A set of symbol, word, code or
instructions which is understood by
What ?
computer
Programming Language
Function?
Method of communication for which
computers could understand and execute
the instructions written in source code.
14
7
Introduction to Computer
Chap 1
Programming
Category Explanation
Machine language Binary number codes understood by a
specific CPU
Assembly Mnemonic codes that correspond to
language machine language instructions
High level Machine-independent programming
language language that combines algebraic
expressions and English symbols.
Introduction to Computer
Chap 1
Programming
8
Introduction to Computer
Chap 1
Programming
An example of a computer
program or software
written in JAVA
programming language
17
Introduction to Computer
Chap 1
Programming
An example of a computer
program or software
written in C++
programming language
18
9
Introduction to Computer
Chap 1
Programming
Computer programmer
How ?
19
Introduction to Computer
Chap 1
Programming
Computer program
person
Programmer
20
10
Introduction to Computer
Chap 1
Programming
Input
Output
21
Introduction to Computer
Chap 1
Programming
Input Output
Process
22
11
Introduction to Computer
Chap 1
Programming
Data
A collection of
unprocessed items e.g:
text, numbers, images,
audio and video
23
Introduction to Computer
Chap 1
Programming
24
12
Introduction to Computer
Chap 1
Programming
25
Introduction to Computer
Chap 1
Programming
Information
result of processing,
manipulating and
organizing data in a way
that adds to the knowledge
of the receiver
26
13
Introduction to Computer
Chap 1
Programming
A computer generates
several types of in text,
output, depending on graphics, audio
the hardware and or video forms.
software being used
and user requirements
27
Introduction to Computer
Chap 1
Programming
Monitor Printer
28
14
Introduction to Computer
Chap 1
Programming
29
Introduction to Computer
Chap 1
Programming
Computer
programmer
WHAT Program ??
30
15
Introduction to Computer
Chap 1
Programming
31
Introduction to Computer
Chap 1
Programming
Specify problem
Design algorithm
Implement algorithm
16
Introduction to Computer
Chap 1
Programming
What is the
What STATE problem?
problem to
be solved?
Is it possible to solve
the problem with
programming?
33
Introduction to Computer
Chap 1
Programming
State the
problem
clearly Gain a clear
understanding of
what are
required for its
solution.
34
17
Introduction to Computer
Chap 1
Programming
What is the
problem?
Given the value of x is 10 and a is 12,
find the result of the following equation: What to
solve?
y = 2x + a - 6
Is it possible to
solve the problem
with
programming?
35
Introduction to Computer
Chap 1
Programming
36
18
Introduction to Computer
Chap 1
Programming
What data
What is the What to we have?
problem? solve?
37
Introduction to Computer
Chap 1
Programming
38
19
Introduction to Computer
Chap 1
Programming
39
Introduction to Computer
Chap 1
Programming
40
20
Introduction to Computer
Chap 1
Programming
Introduction to Computer
Chap 1
Programming
No specific data.
Data
Pay per day,working days
Get the pay per day and amount of
Solution
working days.
Calculate the salary.
42
21
Introduction to Computer
Chap 1
Programming
43
Introduction to Computer
Chap 1
Programming
44
22
Introduction to Computer
Chap 1
Programming
45
Introduction to Computer
Chap 1
Programming
IDENTIFY
Output
Input
Process
46
23
Introduction to Computer
Chap 1
Programming
Input
Given the value of x is 10 and a is 12,
find the result of the following equation:
Process
y = 2x + a - 6
Output
47
Introduction to Computer
Chap 1
Programming
48
24
Introduction to Computer
Chap 1
Programming
Output
Input Process
49
Introduction to Computer
Chap 1
Programming
Develop a formula(s):
payment = amount x price per tin
Process
50
25
Introduction to Computer
Chap 1
Programming
Output
Input Process
51
Introduction to Computer
Chap 1
Programming
Input Mark
Output Grade
52
26
Introduction to Computer
Chap 1
Programming
53
Introduction to Computer
Chap 1
Programming
54
27
Introduction to Computer
Chap 1
Programming
Solve Problem
55
Introduction to Computer
Chap 1
Programming
Writing program
Also known
Convert algorithm into as CODING
programming
56
28
Introduction to Computer
Chap 1
Programming
57
Introduction to Computer
Chap 1
Programming
Testing program
Executing program to see if it
To verify the program can produce correct results.If not
works as desired do debugging.
58
29
Introduction to Computer
Chap 1
Programming
Modifying program
USE and MODIFY the
Remove undetected errors program to meet changing
requirements or correct
and keep up-to-date errors that show up in using
it
59
Introduction to Computer
Chap 1
Programming
Specify problem
Design algorithm
Implement algorithm
30
Introduction to Computer
Chap 1
Programming
61
Introduction to Computer
Chap 1
Programming
62
31
Introduction to Computer
Chap 1
Programming
63
32