You can use the lastindex (or lastgroup) attribute of re match objects, which reports the index (or group name) of the last matched group.
However you have to modify your regular expression in order to transform each subexpression into a group, by enclosing them between brackets:
pat=re.compile('(C[GT]GG)|(A[AT]TA)|(T[TG]TA)')
for m in pat.finditer(longString):
print m.start(), m.end(), 'group index:', m.lastindex
If you like to use symbolic names (thus improving readability), the pattern syntax is a little more complicated:
pat=re.compile('(?P<C_CG_GG>C[GT]GG)|(?P<A_AT_TA>A[AT]TA)|(?P<T_TG_TA>T[TG]TA)')
for m in pat.finditer(longString):
print m.start(), m.end(), 'group index:', m.lastindex, 'group name:', m.lastgroup