letters = ['H', 'T']
matches = re.findall('({})\\1*'.format('|'.join(letters)),
    'TTHHTHHZTHHHHTTHHHTTT')
print(matches)
['T', 'H', 'T', 'H', 'T', 'H', 'T', 'H', 'T']
[(letter, matches.count(letter)) for letter in letters]
[('H', 4), ('T', 5)]
Counting runs in a string