← Questions

Kth largest element in two sorted arrays

0
GleanAmazonCodingLast asked Sep 2026

A coding interview question asked in Glean's coding round and at Amazon, last asked Sep 2026. It tests binary-search, arrays and selection.

You get two integer arrays a and b, each sorted in non-decreasing order, and an integer k. Return the k-th largest value among all elements of both arrays.

Sign in to unlock this question

The full prompt, the worked answer and your own canvas or code with the AI tutor. New accounts get 5 credits: each one unlocks a question for good.

Where it's asked

  • Glean · Coding · Last asked Sep 2026Live coding, usually two rounds
  • Amazon · Technical phone screen · Last asked Mar 202660 min · Live coding in a shared editor that does not run code, plus Leadership Principles questions · No AI

What it tests

binary-search · arrays · selection

Your code and the AI tutor open when you unlock this question.