#P9118. Triangle Rotation

Triangle Rotation

Source: Super League of Chinese College Students Algorithm Design 2022, Contest 10.