Solve problem "Reverse the fragment" online - Learn Python 3 - Snakify

Reverse the fragment


Given a string in which the letter h occurs at least two times, reverse the sequence of characters enclosed between the first and last appearances.

In all the problems input the data using input() and print the result using print().