issue_5: Reject invalid input