FAANG
on
ZestyNoodle
Student
CP DAY-3
Today, I tackled the "Cover in Water" problem on Code forces. QUESTION:-Filip has a row of cells—some are blocked, and some are empty. He wants to fill all empty cells with water using two actions:
- Place water in an empty cell.
- Move water from one cell to another empty cell. An empty cell will automatically fill with water if it is flanked by water on both sides. ➡️ What is the minimum number of times Filip needs to perform action 1 to ensure all empty cells are filled? How would you approach solving this optimization problem? 🤔💡
2mo ago
Find out if you are being paid fairly.Download Grapevine
You're early. There are no comments yet.
Be the first to comment.
Discover more
Curated from across