Published on Tue Mar 01 2022
The first line contains a single integer, , denoting the number of usernames.
Each line of the subsequent lines contains a string denoting an alien username to validate.
Iterate through each of the strings in order and determine whether or not each string is a valid alien username. If a username is a valid alien username, print VALID on a new line; otherwise, print INVALID.
We validate the following three usernames:
_0898989811abced_ is valid as it satisfies the requirements specified above. Thus, we print VALID.
_abce is invalid as the beginning _ is not followed by one or more digits. Thus, we print INVALID.
_09090909abcD0 is invalid as the sequence of English alphabetic letters is immediately followed by a number. Thus, we print INVALID.