← All problemsSign in

Find the Frame

You are given Tand the number of test cases, N, the length of list. On the next line a list of N non decreasing numbers are given, the i-th element of the which is denoted as a[i]. Next, you are given Q queries, each query containing X,Y. X being the frame size and Y the sum required. For each query you need to print if there is a frame of size X in the list, whose sum of numbers is Y. If there ex

HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17

CodeSearch Tutor

Hints, not spoilers — it won’t hand over the full solution unless you insist.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start