corrected for input