#K42592. Serial Number Validation
Serial Number Validation
Serial Number Validation
Given a serial number string, determine if the serial number is valid according to the following pattern:
- Starts with exactly 1 uppercase letter.
- Followed by exactly 3 digits.
- A hyphen ('-').
- Then 2 uppercase letters.
- Ends with exactly 3 digits.
In other words, the serial number must match the following regular expression in LaTeX format:
\( ^[A-Z][0-9]{3}-[A-Z]{2}[0-9]{3}$ \)
Output "True" if the serial number is valid and "False" otherwise.
inputFormat
The input consists of a single line containing a string representing the serial number.
outputFormat
Output a single line containing either "True" if the serial number is valid, or "False" if it is not.
## sampleA123-BC456
True