Recently, I was asked about my opinion on mentoring and pair programming. I thought this would make a great read and I'd share some thoughts and observations. It is going to be mostly about mentoring junior developers.
My Early Days
When I was a junior developer, I had the privilege of working with an amazing colleague who became my mentor. He not only taught me the technical skills, but also provided a friendly and helpful environment to learn and make mistakes. Recently, I noticed that I somewhat followed his trail in how I work and what tools I use. Maybe we were somewhat similar, and I was too dumb "junior" to understand some things back then. Anyway, I'm very glad that I had an amazing mentor during my early career days. In my more advanced days, I’ve also met great mentors and colleagues who continued to inspire and support me.
Becoming a Mentor
As I gained experience, I took on the mentoring role myself. I’ve had the opportunity to participate in local academies, assisting and mentoring junior developers. These experiences have been incredibly rewarding. Watching others grow and succeed, knowing that I played a part in their development, is a great feeling. Mentoring also reinforces my own knowledge and keeps me sharp. Junior devs might struggle in the most unexpected ways, but it is important to let them actually fail—not in a way that takes down production, but in some harmless way. It's usually not that hard to predict the outcome of failing, so I was already prepared and waiting at the point of failure with friendly tips, help, and an explanation of what went wrong. Failure is a part of the learning path. While it is important to guide, it is also important to give freedom for actions and curiosity.
Beyond Books and Courses
I think mentoring is crucial in the IT industry. It helps to create a link between theoretical knowledge and real-world application. A good mentor can provide insights that are not available in textbooks or online courses. They offer a different perspective, share personal experiences, and help mentees navigate their career paths. Moreover, mentoring promotes a culture of learning and collaboration, which is vital for the growth of any individual.
Two Devs, One Screen
Continuing the duo of a mentor and a mentee, pair programming might be another effective method of knowledge sharing. Although some people hate it, others love it. If the leading person is enthusiastic and enjoys the process, it can be a fun and productive way to learn for both the mentor and the mentee. Pair programming allows for real-time feedback and collaboration, yielding results (or local memes). It is important to actually help, not dominate over the poor mentee. For example, if we're solving a bug together, I like to investigate the problem together. Juniors often lack the skill of using debugging tools, so it's important to show how and when to use them. After identifying the problem, I like to sit back, verbally guide the mentee on solving the bug, and watch, giving tips, suggestions, jokes, and explanations along the way.
Although, sometimes pair programming just isn't someones thing and forcing pair programming onto such person is not going to make any good. Don't be an annoying mentor.
Sometimes They Won't Ask
Sometimes junior devs might be too afraid to ask because they think their question is too stupid, or they're ashamed or just afraid to be a nuisance. I always try to encourage juniors to communicate and ask questions. Sometimes a simple unasked question might become a fundamental knowledge gap in the future. Of course, I try not to babysit, but if I see a junior struggling for quite some time, I will approach them myself. If everything is "fine", I try to invite them to discuss some matters of their current task, expressing some of my thoughts about it until they are ready to share their struggle. While it's useful to take some time and try to figure out the problem themselves, there's a line between "taking some time" and "getting completely stuck and just wasting time". Mentor is here for a reason. Not that I want to rush things, It's more about just getting things (eventually) done and learning something new along the way.
If they come with a question – great! If they come with a question for the 50th time today... Not great. To protect myself from becoming the next GPT AI for a mentee, I usually teach them a small "self-help" guide on how to actually get useful help and not make colleagues annoyed and tired of you. First, I usually send them to Google (or any other) search. If there is no help, then I ask them to think about three things:
- What is the problem? In one sentence.
- What is the error message (or any proof showing something is not working)?
- What have you tried to solve the problem?
Around half the time, after these questions, they are able to solve the problem themselves by just trying to "study" the issue to answer these three questions. The other half comes already prepared with some spot-on questions that are easy to deal with.
But I'm Not Getting Paid For That
Yeah, true. Sadly, being a mentor is usually "built-in" in the role. But also, usually, it's not forced to be a mentor. I usually participate in mentoring activities when I know that it won't hurt the project I'm currently in or that it's not of fire right now.
Single-time activities like single lecture are generally not that time consuming, especially since you can prepare once and the re-present it every time with little to no modifications again and again.
Having a junior is usually also quite chill, especially after the onboarding phase.
Participating in academies as a mentor and/or lecturer is IMHO the hardest and most time consuming as academies usually spans across multiple weeks. Sometimes I had to do unpaid "overtime" for the actual project I'm working on, because I spent too much time with the students. But in the end such experience is still quite worthy. After such academy I usually change and adjust my perspective on work things/projects, learn a few things and generally feel somewhat refreshed.
TL;DR
It's quite fun. I am grateful for the mentors I’ve had and the mentees I’ve guided. Let's help each other and not gatekeep the industry.