CS105 – Programming Foundations

Credits 20
Level SHE Level 1
Prerequisites None
Availability Semesters 1 and 2
Elective Yes
Contact 44 lectures and 20 2-hour practicals
Assessment 30% classwork, 70% written exam, with possibility of exam exemption
Lecturer Isla Ross | Dr Murray Wood*
* (Class Coordinator)

Aims and Objectives

To provide the student with a solid foundation in the principles of computer programming. On completing this class the student should have the necessary skills to be able to design, build and test a small system in a high-level language (Java in the current incarnation of the class).

Learning Outcomes

On completion of the class, a student should be able to:

  1. Appreciate the role of a high-level language within the context of a computer system.
  2. Understand the program development process.
  3. Understand the principles of program design and demonstrate their practical application.
  4. Design, implement and test small software systems using a high-level language (currently Java) to conform to a specification.
  5. Demonstrate familiarity with a sophisticated interactive development environment (IDE).


The class aims to provide a good grounding in the basics of programming. An “objects-first” approach means that proper object-oriented programming concepts can be emphasised and explored from day one. The course is iterative, concept-based and project-driven – it covers the important programming ideas via a number of projects and extensive hands-on exercises. It does not attempt to provide a complete coverage of the language, but aims to introduce the basics which are then built on in later classes.

Main topics covered:-

  1. Background: Introduction to the purpose of high level languages and the development and compilation process.
  2. The fundamental concepts of programming:
    • Key concepts of objects, classes, methods, parameters, data types etc.
    • Defining classes – fields, constructors, methods, parameters, assignment.
    • Defining methods – local variables, blocks, control structures (conditionals and loops).
    • Inter- and intra- object communication – object references, method calls, parameter passing, return values etc.
    • Collections of objects – arrays, arraylists (e.g.), iterators.
    • Abstraction mechanisms: Library classes and the API – introduction to the API, documentation, use of key library classes.
    • Abstract data types – commonly used types such as Map, Set etc.
    • More abstraction mechanisms – inheritance, interfaces, sub typing, polymorphism etc.
    • External communication – e.g. input and output, GUIs, file handling and exceptions.

    These concepts are currently realised using Java.

  3. Principles of program design and testing: Documentation (e.g. javadoc), basic testing principles, test automation using tools such as the xUnit family, debugging, basic Class diagrams.
  4. Development environments: Initially the class makes use of a relatively simple and supportive environment (such as BlueJ) to illustrate and emphasise the key concepts (classes, objects, method calls etc.) and support easy development. As the course progresses it will make greater use of a more sophisticated environment (such as Eclipse) that is also of use in the subsequent years of the course.

Assessment and Exemption

Weekly assignments are set and submitted for marking in the laboratory. Overall these contribute 10% of the total mark for the class. There are also four class tests, held towards the middle and end of each semester. These tests are practical programming exercises which require the students to write code at the machine under examination conditions. They are also marked at the machine. Worth 4% each, these contribute towards a total of 20% to the mark for the class. Students scoring at least 15/20 for the four tests and the inter-semester exercises (see below) are then eligible to attempt an additional project set by the class lecturer. A mark of at least 60% for this project entitles the student to an exemption for the class.

Additionally, the inter-semester break will be utilised and one or more significant exercises set and assessed within this period. This is a compulsory exercise to be marked by demonstration and will contribute 4% (combined with the four test marks to bring the total up to 20%).


The resit for the class will take the form of a two-hour examination. The resit examination will be designed to test all aspects of the course. The mark returned for the resit attempt will be based upon the resit examination alone.

Indicative Reading*

* This list is indicative only – the class lecturer may recommend alternative reading material. Please do not purchase any of the reading material listed below until you have confirmed with the class lecturer that it will be used for this class.

David J. Barnes & Michael Kölling, Objects First with Java – A Practical Introduction using BlueJ, Fourth Edition, Prentice Hall / Pearson Education, 2008 ISBN-10: 0-13-606086-2 ISBN-13: 978-0-13-606086-4

Kathy Sierra and Bert Bates, Head First Java, Second Edition, O’Reilly, February 2005. ISBN-10: 0596009208 ISBN-13: 978-0596009205