Trees, BSTs & Linked Lists
Four different-looking asks share one row in a Walmart coding round, and it helps to meet them as a family. A tree problem hands you a recursive object and asks you to solve the two subtrees, then fold the current node into their answers. A binary search tree adds one rule on top of that shape, an ordering that has to hold everywhere below every node. A linked list asks you to move pointers along a chain and rewire the links without losing your place. None of it is exotic. The band sits at reliable medium, the editor runs your code, and the bar is a correct first pass with a clean follow-up rather than a flash of insight.
The through-line is simple: think clearly about a structure made of nodes and pointers, and build it yourself from the raw input the interviewer hands you. That input is almost always a level-order array for a tree or a sequence of values for a list. Turning it into real nodes is your first job, and no library does it for you. Drill the traversal until your fingers know it, and your head stays free for whatever the problem wraps around it.
- 4 problems, worked step by step
- about 33 min
Premium lessonWalmart 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
Walmart interview guideKnow what Walmart asks before you walk in.
24 coding · 4 system design · 20 behavioral questions
Get their questions first.
InterviewLegend is independent and not affiliated with or endorsed by any company it covers.