Simulate pouring water onto terrain | Airbnb Coding Question