added error message for division by zero