Given an all upper case string, check if it is a combination of one or more of the following:
First line contains an integer T denoting the number of test cases. Each of the following T lines will contain an upper case string.
Print YES if the sequence is correct, NO if not correct.
1<=10^5<= Size of String
If you have purchased any course from GeeksforGeeks then please ask your doubt on course discussion forum. You will get quick replies from GFG Moderators there.