This test will be worth between 40-50% of the final mark.
-
You must write all of the code for the exam in a
single file called exam.cpp
-
In order to speed up code writing you DO NOT have to
put your code into separate .h and .cpp files. You may write all of the code
directly inline in a single .h file.
-
You must email me exam.cpp at the end of the test
and you must ensure that I (or the demonstrator) has acknowledged reception
before you leave the room.
-
You must also copy exam.cpp onto a floppy disk and
give this to me before you leave the room.
-
Make sure your name appears as a comment in the top
of exam.cpp
- Comments in code (but due to time brief one line descriptions of methods are OK)
- Structure (indentation) of code
- Understanding the concept of a class and objects of a class.
- Identification of well formed classes which provide well defined services..
- Data encapsulation.
- Factorisation of the problem into independent classes or groups of classes.
- Understanding of the use of basic C++ constructs such as input/output, branching, inheritance, references...
- Handling collections of objects ...
This examination is designed to test your understanding of the philosophy of OO programming (in C++) when applied to a complete problem.
You are presented with a programming request and your job is to develop an appropriate set of classes which you then use together to perform the task. You are NOT told what classes to write. It is part of the test that you to identify and write suitable classes.
In your code you should try to avoid the creation of unnecessary copies of objects where this is appropriate.
For reasons of time you do not need to attempt use the const qualifier anywhere in this test. You will also not need to know about enumerated constants.