InterviewLegend

Heaps & Intervals

Alex Chen26 min readUpdated

This family shows up wherever a Plaid round works with time windows or with a set where you keep needing the current best. Both are everywhere in the product. Pending charges place holds that span a range of minutes. Connections have windows of days when a refresh is worth pulling, and settlement and statement periods overlap. Behind all of it sit rate limits that force you to pick which waiting job runs next. Sorting the windows and sweeping across them is the interval half. Keeping a heap so the next best item is always one pop away is the priority half. The two show up together often enough that this lesson takes them as one section.

There is no hidden trick to decode in these. They are canonical problems asked close to the way you already know them, with a transaction-flavored prompt wrapped around the core. The pressure Plaid applies is the one it applies everywhere in the coding loop. The base solution has to run and pass the given cases, money stays in integer units, and the interviewer wants the time and space cost named before moving on. Then a new requirement lands. Report the peak instead of the merge. Allow a third pick. Refresh more than one connection a day. A clean base you can write without fumbling is what buys you room for the layer that comes next, since the follow-up is where most of the signal lives here.

The Plaid angle
A pending hold is a time window, so consolidating holds on an account is a Premium question in Plaid's own data. When a card is authorized, the bank places a temporary hold that spans a range before it posts or drops off, and an account can carry several holds at once. Reporting the consolidated periods when money is tied up is a Premium question. Sort the holds by when they open, then walk once, extending the current window whenever the next hold starts before it ends.
What's inside
  • 4 problems, worked step by step
  • about 26 min

Premium lessonPlaid interview guide

These took digging.

What candidates walked out with, from 20,000+ reports, forum threads behind logins and write-ups in Chinese. Then solved step by step.

100 companies. Checked every month.

Unlock all 100 companies

$49 a year · less than $1 a week · Cancel anytime

Had your Plaid interview?Tell us what they asked. Reviewed before it goes in, never with your name.
Plaid interview guide

Know what Plaid asks before you walk in.

16 coding · 5 system design · 18 behavioral questions

Get Premium$49 a year · Cancel anytime
Or start freeNo card.

Get their questions first.

InterviewLegend is independent and not affiliated with or endorsed by any company it covers.