Arrays and Two Pointers
Arrays and two pointers take the largest share of eBay's live coding rounds, from US phone screens to onsite rounds in India. Most problems are LeetCode mediums that arrive close to their standard form, sometimes with a change to what you return.
Most of them get easier with one of two moves. If order doesn't matter, sort first so equal values sit next to each other. If each position carries meaning, you can't sort, and two pointers starting at both ends often do the work instead.
Repeated values cause more wrong answers here than slow code does. Prices on a marketplace repeat, since two listings can share a price, and your answer usually has to report each result once. Decide how you'll skip duplicates before you write the loop.
Hard problems don't come up often at eBay, but one in this set once filled a 30-minute round on its own. It needs a different tool, counting inside a merge sort, so give it more practice time than the mediums. Each problem below is worked end to end.
eBayPremium lesson · Coding round
The 4 eBay problems are below.
- A Premium questionCoding · Medium · Signature problem
- A Premium questionCoding · Medium
- A Premium questionCoding · Medium
+ 1 more in this lesson
Each with hints, the follow-up and a tested solution.
Get the eBay questions$49 a year · all 100 companies · cancel anytime
From 266 eBay reports, forum threads behind logins and write-ups in Chinese.
eBay interview guideKnow what eBay asks before you walk in.
33 coding · 5 system design · 30 behavioral questions
Get their questions first.
InterviewLegend is independent and not affiliated with or endorsed by any company it covers.