The first line contains an Integer 'T' which denotes the number of test cases or queries to be run. Then the test cases follow. The first line of each test case consists of a string ‘S’ which denotes the IFSC Code.
For each test case print ‘True’ if the IFSC code is valid otherwise print ‘False’. Output for each test case will be printed in a separate line.
You are not required to print anything, it has already been taken care of. Just implement the function.
1 <= T <= 10 1 <= |S| <= 100 Time Limit: 1 sec
To check whether the string is a valid IFSC Code or not we can check every character of the string explicitly and check whether the string is in the correct format or not.
Ninja and Numbers
Longest Palindromic Substring