implement putTask

is not yet tested, but compiles.