Sliding window max (peeked a bit)
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
import json
|
||||
|
||||
import pytest
|
||||
|
||||
import stuff
|
||||
@@ -465,7 +467,11 @@ def test_trie_busy():
|
||||
[-2, 1],
|
||||
1,
|
||||
),
|
||||
(
|
||||
json.load(open(".testdata/max_sub_array0.json")),
|
||||
11081,
|
||||
),
|
||||
],
|
||||
)
|
||||
def test_maximum_subarray(nums: list[int], expected: int):
|
||||
def test_max_sub_array(nums: list[int], expected: int):
|
||||
assert stuff.sum_max_sub_array(nums) == expected
|
||||
|
||||
Reference in New Issue
Block a user