Ship Traffic
Jump to navigation
Jump to search
- calculate the time that any given ship would start blocking the ferry in that lane, and stop blocking the ferry in that lane
- convert these all to times that the ferry can start, leaving us with a list of times that the start Starts getting blocked, and stops getting blocked
- sort this list and walk it...any time there are 0 boats blocking the ferry, check if the gap to the next ship starting to block is the longest
This is another one of those "I can't believe this is a finals problem"