working on i/o redirection