COS 201
Computer Programming I
3
Course Description
At the end of this course, students should be able to:
1. explain the principles of good programming and structured programming concepts;
2. explain the programming constructs, syntax and semantics of a higher-level
language;
3. describe the chosen programming language variables, types, expressions,
statements and assignment; simple input and output;
4. describe the programme control structures, functions and parameter passing, and
structured decomposition; and
5. develop simple programmes in the taught programming language as well as debug and
test them.
Course Outline
Introduction to computer programming. Functional programming; Declarative programming;
Logic programming; Scripting languages. Introduction to object-orientation as a technique for
modelling computation. structured, and even some level of functional programming principles;
Introduction of a typical object-oriented language, such as Java; Basic data types, variables,
expressions, assignment statements and operators; Basic object-oriented concepts:
abstraction; objects; classes; methods; parameter passing; encapsulation. Class hierarchies
and programme organisation using packages/namespaces; Use of API – use of
iterators/enumerators, List, Stack, Queue from API; Searching; sorting; Recursive algorithms;
Event-driven programming: event-handling methods; event propagation; exception handling.
Introduction to Strings and string processing; Simple I/O; control structures; Arrays; Simple
recursive algorithms; inheritance; polymorphism.
Lab work: Programming assignments; design and implementation of simple algorithms e.g.
average, standard deviation, searching and sorting; Developing and tracing simple recursive
algorithms. Inheritance and polymorphism.