Back to problems

DE / AE Screen: SQL + Python (Sliding Window + Joins)

SQL · DoorDash · Medium

Requirements Python (1 question) Given a list of integers, find the contiguous window with the greatest sum and report its starting day using a 1-based index. Use a list of starting days when every optimal window must be reported; when the window size is fixed and only one result is expected, a single integer is acceptable. State how ties should be handled. A suitable function signature is: Here, k is the fixed window length. If the intended contract returns only one…

Checking your access…