Rosetta Problems

Choosing Flowers for the Flower Bed

https://atcoder.jp/contests/awc0057/tasks/awc0057_d