MSc-IT Study Material
January 2011 Edition

Computer Science Department, University of Cape Town
| MIT Notes Home | Edition Home |

Review

Questions

Review Question 1

Why is the importance of abstraction?

Discussion of this question can be found at the end of this chapter.

Review Question 2

What is the main technique for implementing information hiding?

Discussion of this question can be found at the end of this chapter.

Review Question 3

Complete the following:

Refactoring is the activity of changing the software's [________________] without changing its [_______________]. It is specifically concerned with improving the software's [____________________].

During refactoring, software is examined for three things, namely:

  1. [___________________]

  2. [___________________]

  3. [___________________]

Discussion of this question can be found at the end of this chapter.

Answers

Discussion of Review Question 1

Abstraction allows us to focus on the relevant portions of a problem and our design. It allows us to simplify our representation of how actions are carried out (procedures) and how data is represented (such as by using classes and objects).

Abstraction also allows us to represent our software at various levels of detail.

Discussion of Review Question 2

Software modules are the main tool used to implement information hiding. They segregate a portion of the information contained within a software system from the rest of the system, and control access to this information. Examples of software modules include C++ and C# namespaces, Java packages, and classes and objects.

Discussion of Review Question 3

Refactoring is the activity of changing the software's internal structure without changing its external behaviour. It is specifically concerned with improving the software's internal structure.

During refactoring, software is examined for three things, namely:

  1. Redundant code

  2. Unused design elements

  3. Poorly constructed data structure