First page Back Continue Last page Overview Graphics

Classes and Swig

10:17:59

We will write a class

clock in C++ with a Python

interfacefor a digital clock.

It should implement the following methods:

set (hours, minutes, seconds = 9);

tick();

The method tick() should “tick” for a second, i.e. the time should be advanced by one second:

11:59:59 → 12:00:00