logging: printing output also on screen