← All problemsSign in

GEETs LOVE TEST

Aditya is in love with Geet , but Geet wants to take Aditya’s Love test so she gives Aditya N array elements and asks Aditya to find a subsequence of size $K$ The selected subsequence should have the following characteristics - The selected subsequence should be non-decreasing. - The gcd of indexes of two adjacent elements should be the first element of the chosen indexes for example let the in

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