Forgot the output logic for the completed output.