Available question text
Design a data structure that supports point-add updates to nums2 and count queries that return how many pairs (i,j) satisfy nums1[i] + nums2[j] == tot. The challenge is to answer many updates/queries efficiently (nums1 is relatively small) by maintaining frequency bookkeeping rather than recomputing all pairs.
Related questions
Continue with questions that share topics or the same question type.
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 1865. Finding Pairs With a Certain Sum
Reported date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source