Available question text
Given two sorted arrays of distinct integers, find the maximum sum obtainable by traversing left-to-right along either array and optionally switching arrays at common elements; at each intersection you may choose the path with the larger accumulated prefix sum. Input sizes up to 1e5 and result must be returned modulo 1e9+7, so a linear two-pointer/merge-like approach is required.
Related questions
Continue with questions that share topics or the same question type.
- Find and Count Maximum-Score Grid Paths
Coding · Dynamic Programming · Grids & Matrices
- Find the Maximum Divisibility Score
Coding
- Find the Maximum Factor Score of Array
Coding
- Get Maximum in Generated Array
Coding
Sources · 1 reference
These records explain where the question appears. A company tag or candidate report does not guarantee a future interview question.
Hello Interview · 1 record
No company association
Leetcode 1537. Get the Maximum Score
Reported date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source