added procedure for user-input