← Amazon questions

Find number existence in window of k numbers with min comparisons

Filed under Amazon

Given an incoming stream of integers and a window size k, write code to find whether a specific target number exists in the current sliding window with the minimum number of comparisons.

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Amazon questions

Collected from public candidate posts and coding forums. Updated Nov 2026.