feat(content): function signatures + test cases

This commit is contained in:
2025-07-13 19:53:34 +01:00
parent d65ccf7dc2
commit 0262ca8bf6
203 changed files with 4526 additions and 0 deletions

View File

@@ -9,6 +9,26 @@ categories:
patterns:
- greedy
function_signature: "def max_score_sightseeing_pair(values: list[int]) -> int:"
test_cases:
visible:
- input: { values: [8, 1, 5, 2, 6] }
expected: 11
- input: { values: [1, 2] }
expected: 2
hidden:
- input: { values: [1, 3, 5] }
expected: 7
- input: { values: [1, 1, 1, 1] }
expected: 1
- input: { values: [10, 1, 1, 1, 1, 1, 10] }
expected: 15
- input: { values: [5, 4, 3, 2, 1] }
expected: 8
- input: { values: [1, 2, 3, 4, 5] }
expected: 8
description: |
You are given an integer array `values` where `values[i]` represents the value of the i<sup>th</sup> sightseeing spot. Two sightseeing spots `i` and `j` have a **distance** `j - i` between them.