changed some input/output