Flower placement and directory deletion

0
Remix

Two problems in one round:

  1. A row of plots has some flowers planted already, and no two flowers may be next to each other. Decide whether n more flowers can be planted.
  2. Given a directory structure, delete a directory together with everything inside it.
GoogleCodingLast asked May 2026
No answer yet. Write the first one; the best answer gets endorsed.