Pergunta de entrevista da empresa Sixt

Sliding window maximum question with code