import reprint(re.findall('[A-Z]+',"assAAhhhAB"))
Standard input is empty
['AA', 'AB']
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!