Nguyen Le Phong

What Junior Developers Actually Need From a Mentor

New grads can code.

A junior teammate's PR lands in your queue just before lunch. It works. The tests pass. But every network call is wrapped in the same retry helper, including the one that writes a payment record, and there's a try/catch that logs the error and carries on. The code isn't wrong so much as nervous. It reads like someone guessing at what might go wrong.

You could leave three comments ("remove the retry here", "don't swallow this error", "move this to the service") and get back to your own work. Or you could ask one question first: "What were you worried about when you added the retry?" The answer tells you which problem you're looking at. Maybe they're missing a skill. Far more often, they're missing context nobody gave them.

A senior engineer and a junior developer look over a small pull request together, a coffee mug next to the keyboard.
A small PR is often the best mentoring material you'll get all week.

New grads can code. They get stuck somewhere else.

In a 2008 paper, Andrew Begel (Microsoft Research) and Beth Simon (UC San Diego) described spending 85 hours over two months shadowing eight recent college graduates at Microsoft who were still in their first six months on the job (Struggles of New College Graduates in their First Software Development Job). The new hires were good at the things school teaches: programming, writing design specs, sticking with a hard problem. Of the five areas where they got stuck, only one was technical. The rest were communication, collaboration, cognition and orientation, that last one meaning finding their way around a big codebase and the people who know it.

One line from the paper is worth taping to your monitor: new developers "do not ask questions soon enough." Some believed they had to do everything themselves to look good to their manager. Others kept working on issues they felt they "should know" instead of admitting they were stuck. And one had to ask his manager for a mentor after four weeks, then found the mentor was too busy to help.

So when a junior's code looks shaky, the gap is usually not syntax. They don't know which module is fragile, which rule is a real business rule and which is a leftover from 2019, or how much risk is "ask first" territory. And they're often afraid that asking will make them look like a bad hire.

Hand over the map before the task

The Begel and Simon paper also describes a team lead who got this right: he kept asking for the new hire's input and kept "sprinkling in background information on the code and design decisions" from his own history with the project. That's the cheapest mentoring there is. Before a junior starts a task, spend five minutes on:

  • What the feature is for, and who notices first if it breaks.
  • Which earlier decision shapes it ("we store amounts in cents because of the 2023 rounding bug").
  • Where the sharp edge is: the payment write, the migration, the shared config.
  • What a good-enough first version looks like, so they know when to stop polishing.

Back to the nervous retry. With this briefing, the junior would have known that payment writes must never be retried blindly, because a retry can charge someone twice. That's a fact about your system. No amount of talent would have told them.

A senior engineer sketches a simple architecture diagram for a junior developer next to a laptop before the work starts.
Five minutes on the whiteboard: what it's for, what it touches and where it can hurt someone.

Answer fast, and you teach them to borrow your certainty

Most new mentors start out as the team's search engine. Someone asks, you answer. Someone hits an error, you recognize it in two seconds. It feels generous, and people keep coming back, which feels even better. But the junior learns that the fastest way out of confusion is to ask you, and you've built a dependency you'll be paying off for months.

Education researchers named the fix decades ago. Allan Collins, John Seely Brown and Ann Holum called it cognitive apprenticeship (Cognitive Apprenticeship: Making Thinking Visible, 1991). In a traditional craft, an apprentice can watch the master work. In school and in most offices, the thinking stays hidden inside the expert's head. Their model has the expert show the reasoning out loud, support the learner while they try (scaffolding), then remove that support step by step as the learner gets better (fading).

In practice, that means answering the question and narrating how you'd find the answer: "First I'd grep for that error code, then check what changed in the last deploy, because this endpoint was fine yesterday." Next time, the junior can run that path without you.

Scaffolding works best when you agree on it up front. Something like: show me your plan before you write code, ping me if the data model needs to change or the error points outside this module, and handle everything else yourself for the first version. The junior knows where the safety net is, and you're not hovering.

Let them make mistakes you can afford

A junior who never gets to make a mistake never feels the weight of a decision. Your job is to keep the blast radius small, and that doesn't mean taking every risk away. Let them pick an approach you wouldn't have picked. Let them miss an edge case in a low-risk corner, or spend an extra hour on a test failure you'd have spotted in five minutes. Afterward, ask which signal they'd look for earlier next time.

Code review is where this goes well or badly. When a PR has a dozen problems, it's tempting to teach architecture, naming, testing and error handling in one thread. That buries the person. Pick the two lessons that matter most, help them merge safely, and save the rest for pairing or the next task.

All of this depends on whether people feel safe being wrong out loud. Amy Edmondson's study of 51 work teams at a manufacturing company defined team psychological safety as "a shared belief held by members of a team that the team is safe for interpersonal risk taking" (Psychological Safety and Learning Behavior in Work Teams, 1999). Teams with more of it showed more learning behavior: asking for help, seeking feedback, talking about errors. That learning behavior was how safety connected to performance. Edmondson also argued that leaders matter here because people watch them closely, and a leader who responds to questions and challenges without getting defensive tells the team it's safe.

For a mentor, the test is small and concrete. A junior messages "I think I broke staging." Your first reply teaches the whole team what honesty costs. "Thanks for flagging it fast, let's look together" makes the next confession come sooner. A sigh makes it come later.

A junior developer explains an implementation trade-off to a teammate while a senior mentor listens nearby.
The goal: one day they're the one explaining the trade-off, and you're just listening.

Their questions are a bug report on your team

Mentoring also shows you where your team's setup is weak. If three juniors ask the same question, your onboarding has a hole. If every task needs private context from one senior engineer, your codebase is hiding its history. If people wait days before asking, your team has rewarded looking certain over learning. Each answer you give in a DM helps one person once. Put it in the README, the decision record or a code comment, and it helps everyone who comes after.

Progress is easy to miss while it's happening. Then one sprint you notice the same developer who used to wait for your thumbs-up is explaining a trade-off to someone newer. They write a PR description that answers your questions before you ask. They ping you early, and they don't apologize for needing context. That's independence, and you got there by stepping back one notch at a time.

If you want the step-by-step mechanics (pairing, think-alouds, handing over control rung by rung), the culture series covers them in How to Mentor Engineers Without Doing Their Work for Them.

Try this week

  • Before your junior's next task, give a five-minute briefing: what it's for, what it touches, where it can hurt, what "done" looks like.
  • Next time they ask you something, answer and say how you'd have found it yourself.
  • Agree on two or three checkpoints, then stay out of the way between them.
  • Write one answer you've given in a DM into the README.
What did you think?

Frequently asked questions

What do junior developers struggle with most in their first job?
Less with coding than you'd expect. A Microsoft Research study that observed eight new graduates in their first months on the job found they programmed well. Of the five areas where they got stuck, only one was technical. The others included communication, collaboration and finding their way around the codebase. They also tended to ask questions too late.
How do I mentor a junior developer without making them dependent on me?
When you answer a question, also say how you'd have found the answer yourself. Agree on a few checkpoints, like a plan review before coding or a ping when the data model changes, and let them handle the rest. Then pull that support back as they get better.
Should I let a junior developer make mistakes?
Yes, as long as the blast radius is small. Let them choose an approach or miss an edge case in a low-risk area, then talk afterward about which signal they could have spotted earlier. Keep payments, data migrations and shared config behind a checkpoint.