import reword = "aorta"print(re.sub('([AEOUaeouy])(?=[aeoui])', r'\1[=]', word))
Standard input is empty
a[=]orta
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!