All challenges
Multiple ChoiceIntermediate 30s

Max Subarray Sum (Fixed Window)

Finding the max sum of k consecutive elements with sliding window has complexity:
Options
  1. 1O(n)
  2. 2O(n²)
  3. 3O(k log n)
  4. 4O(n·k)

Think you can answer under pressure?

Get matched and answer live questions in 3-minute 1v1 battles. Elo ranking, badge tiers and bragging rights on the line.

Play this in a 3-minute battle