I agree with you @BigEd781 if the input has to follow some pattern, like file names or IPs etc. but if it's a simple number I think regex is overcompicated