Intro To Computer Prog - Lecture 1 - 2
Intro To Computer Prog - Lecture 1 - 2
Introduction to Computer
Programming
BY
Frederick Edem
Broni
Dpt. Of Computer Science and Engineering
•Introduction
•Algorithms and Flowcharts
•Basic Syntax
•Control Flow
•Data Structures
•Advanced Topics
• Python Libraries
• Assignments
• Quizzes
• Lab
• Projects
• Final Exam
• Program
– A list of instructions written in a special code, or
language.
– The program tells the computer which operations to
perform,
– and in what sequence to perform them.
– Garbage In, Garbage Out (G.I.G.O.)
– Get what you asked for, not necessarily what you
want.
• Scientific Applications
• Business Applications
• Artificial Intelligence
• Web Software
• IBM Assembler
A Reg1, memory_cell ; Reg1 = Reg1 + memocell
AR Reg1, Reg2 ; Reg1 = Reg1 + Reg2
• VAX Assembler
ADDL operand1, operand2
Introduction to Computer
Programming Pt 2
BY
Frederick Edem
Broni
Dpt. Of Computer Science and Engineering
Assembler version
Input
Inpu
t
• 1. Analysis
– Is the computer the appropriate tool for solving this
problem?
– Would the problem be better solved with human
interaction or paper and pencil?
– Sometimes human judgment is preferable.
• 3. Develop an Algorithm
– Algorithm:
• a finite sequence of effective statements that when
applied to the problem, will solve it.
– Effective Statement:
• a clear unambiguous instruction that can be carried
out.
– Algorithms should have:
• specific beginning and ending that is reached in a
reasonable amount of time (a finite amount of time).
– This is done before sitting down at the
computer.
Intro to Computer Prog – Frederick Edem Broni 04/29/2025 Slide 80
Algorithms
• 5. Interpretation
– The program may execute without any obvious
errors.
– It may not produce the results which solve the
problem.
• G.I.G.O Get what you ask for,
not what you want.
• Recheck your program with the original specifications
S truc tu re C h a rt
M ain T a sk
S u b ta sk S u b ta sk S u b ta sk
• Pseudocode
• Vocabulary
– reserved words
• have a predefined meaning that can’t be changed
– library identifiers
• words defined in standard libraries
– programmer supplied identifiers
• defined by the programmer following a well defined
set of rules
• Executable Statement
– basic unit of grammar
• library identifiers, programmer defined identifiers,
reserved words, numbers and/or characters
– A semicolon terminates a statement in many
programming languages
• Programs should be readable
Noformat.py format.py