Playtech interview question

A programming task: I had figure out what the code does and then extend it with one more method.