https://fluca1978.github.io/2023/03/06/PerlWeeklyChallenge207.html#task2