267
88
Recently, I started my first job as a junior developer and I have a more senior developer in charge of mentoring me in this small company. However, there are several times when he would give me advice on things that I just couldn't agree with (it goes against what I learned in several good books on the topic written by the experts, questions I asked on some Q&A sites also agree with me) and given our busy schedule, we probably have no time for long debates.
So far, I have been trying to avoid the issue by listening to him, raising a counterpoint based on what I've learned as current good practices. He raises his original point again (most of the time he will say best practice, more maintainable but just didn't go further), I take a note (since he didn't raise a new point to counter my counterpoint), think about it and research at home, but don't make any changes (I'm still not convinced). But recently, he approached me yet again, saw my code and asked me why haven't I changed it to his suggestion. This is the 3rd time in 2--3 weeks.
As a junior developer, I know that I should respect him, but at the same time I just can't agree with some of his advice. Yet I'm being pressured to make changes that I think will make the project worse. Of course as an inexperienced developer, I could be wrong and his way might be better, it may be 1 of those exception cases.
My question is: what can I do to better judge if a senior developer's advice is good, bad or maybe it's good, but outdated in today context? And if it is bad/outdated, what tactics can I use to not implement it his way despite his 'pressures' while maintaining the fact that I respect him as a senior?
+1 great question. I'm struggling with this same situation right now. – Joshua Smith – 2011-05-23T16:56:16.260
A piece of steak came to mind... Obviously offtopic... – duros – 2011-05-23T17:43:24.927
26You learn more from mistakes than successes. – StuperUser – 2011-05-23T17:54:16.350
45Can you give an example of one of the issues you two disagree about? I know this is more of a theoretical question, and you probably want to avoid technical debates, but it would be interesting to hear what the disagreement is over. – Adam Rackis – 2011-05-23T18:09:33.940
5Yes we all think we know best (especially when we are young but even when we are old and crotchety). In the end the senior makes the call because it is the senior that will get the largest chunk taken from his butt if you fail. – Loki Astari – 2011-05-23T18:17:34.233
5Always keep in mind that just because something is in a book doesnt make it correct. On the other hand, he should be giving you some room to develop your own programming style. – GrandmasterB – 2011-05-23T18:29:12.853
4If the senior can't give you good reasons why they are ignoring industry best practice, then get another job where the seniors are reading the same books. If you read books and blogs then you are already better than 90% of the market. If there's no market in your town, move to a better town. – kevin cline – 2011-05-23T20:32:07.133
4There's more than one way to skin a cat, as they say. It may be that the way OP's superior wants to do things isn't the best possible approach, but most likely it will produce at least acceptable results for the company. But OP himself is not likely to get an acceptable result from his first job if he starts off by disagreeing with the guy in charge. Fitting in is part of the job; if you can't do that you're no use as a team player. – FumbleFingers – 2011-05-23T21:04:17.180
1I agree with Kevin. Trust your feelings but think before you act. – narcisradu – 2011-05-23T21:40:49.097
140I see one red flag in this post. You have had to be asked to do something three times. Once should be enough. If you don't want to do something, you need to convince your mentor it isn't necessary. If you can't do that, then either hold your nose and do it, or find a new job. – PeterAllenWebb – 2011-05-23T21:50:35.257
The answer may be that you simply have poor judgment and should listen to your mentor, or it may be that your mentor has poor judgment and you need to either ask superiors to be transferred or seek another job, but it's not possible to tell without details. – Jim Balter – 2011-05-23T21:52:38.033
6@peterallenweb, indeed it is bad to be asked 3 times regardless of the quality of the advice. I guess from the comments here I have a lot to learn in terms of working in different teams. :) – learnjourney – 2011-05-24T00:10:16.337
coming up with the last point does not make you nor him right. – Display Name – 2011-05-24T08:42:31.933
33In addition to what Peter said: Consider his point of view: You ask the new guy to do something, have a technical discussion, get no further objection, and then - a week later you find out he simply ignored your request. And this isn't the first time this has happened. (Don't worry too much - you're certainly not the first person straight from college to fall into this trap. As long as you are aware of this issues and work on them, you'll be alright.) – Martin – 2011-05-24T08:48:42.643
1@learnjourney: In the end you did absolutely the correct thing. Seniors don't know everything either, and software is a collaboration of effort. It's possible you've hurt a relationship with your current "mentor", but you've strengthened a relationship with a different one so it evens out. It never hurts to get an external opinion, and if your current mentor takes it personally, that is a reflection on him not you. Continue stretching your knowledge and trying new things. These are good traits. Don't get discouraged if every great idea you have doesn't get used though. – Joel Etherton – 2011-05-24T13:45:43.893
6@learnjourney When I was a new developer, a much wiser Senior Developer once told me that it was a good idea if I left my ego at the door. It's the best advice I've ever received. If you have a different idea, then bring it up and be prepared to defend it, but if the senior person overrules it then hold your nose and just write the code the way that they want. If they won't budge on an idea then bring it up to your manager that you would like a new mentor, or find a new job. – bakoyaro – 2011-05-24T15:45:56.117
2Hilarious post. Do you still have a job? – Trevor Boyd Smith – 2011-05-24T21:05:20.403
Your evaluation of the code and your colleagues are probably about right. It sounds like you strengthened a relationship with the really important guy: the one with a clue. Those are the kinds of friends you need. People move around a lot in this business, and the more friends you have, and the more capable they are, the better off you will be. In the long run, it doesn't much matter if the clueless guy doesn't like you, because you don't want to follow him anyway. But if the smart guy leaves, you may be interested in following him. – kevin cline – 2011-05-25T05:46:20.987
3One point of your question is ambiguous, are you being advised or instructed to make a change? If you are instructed to do so, do it now. If merely advised, politely explaining your choice is acceptable. – Thomas Langston – 2011-05-25T14:28:51.213
2"I don't understand why this is the correct choice." is always appropriate response if you disagree with a mentor. If the choice is significant, and one of the mentor's peers agrees with you, having your mentor and their peer discuss the choice together with you may help illuminate the issue. – Thomas Langston – 2011-05-25T14:33:47.673
2Accusing someone senior of not knowing anything is pretty arrogant of yourself don't you think? Maybe your code is so hideous they don't think it is worth arguing about or salvaging? I mean if you can't follow simple coding guidelines, maybe the "intricacies" of your code are actually spaghetti code anti-patterns to someone more senior and they don't think your project is worth the effort to correct? I mean, my speculation isn't any more accurate than yours, right? – Jarrod Roberson – 2011-08-19T17:02:56.390
1If your code has intricacies you have very good place to start improving. It should be as clear as glass. – None – 2011-08-19T17:07:34.830
2Great question, but all the replies only reveal how pompous and arrogant these so-called "seniors" are, when mostly they have dull, uninteresting minds like mushy peas. The only solution is a swift punch in the throat to shut them up! More seriously though - if your "mentor" is teaching you bad habits, by all means go work somewhere else! Having no mentor is better than having an idiot to guide you. – Luke Van In – 2011-09-10T19:49:56.820
1Happened to me. Working with senior developer who thinks very high of himself. Tell him in his face everything bad about his code. He takes offense and we fall out. He cannot say "Jeez, you're right, I need to actually read a few up-to-date books, why don't you become the software lead as you know more about this than I do". I hate people who take things like this personally. Unfortunately, 90% do. You cannot tell them that they are wrong because they take offense. I haven't worked with him since then. You get farther if you suck up to their ego. – siamii – 2011-12-29T23:50:22.810
1@lukevanin how would you feel if a lot younger developer, who just came out of college, did a better job then you as senior developer. Would you feel threatened? – siamii – 2011-12-29T23:53:19.357
2@bizso09 I think many seniors would be grateful for the opportunity to reduce their workload and improve their skills by working with someone who can do it better. Programmers worthy of the "senior" title will recognise and leverage whatever abilities they see in others. – Luke Van In – 2011-12-31T10:57:49.583