Part of 2016 Austria Beginners' Competition
Source: 47th Austrian Mathematical Olympiad Beginners' Competition Problem 4