I would like to find matches between two list of AA strings so that 1 of these 3 rules is matched :
1) query string has to be a substring of subject string
2) query string has to end with the same pattern the subject string starts (any number of characters)
3) query string has to start with the same pattern the subject string end (any number of characters)