Improved console input/output