BUG: Fix print statements in doctests

Module level imports affect the execution of the doctests, hence
everything failed in the build of the previous commit of this branch.

Move everything from `print x` to `print(x)`.