Earlier quoted context omitted.
Wait wait wait. Not so fast. i'm one of those programmers who read manuals and stack traces but I have to admit that I've seen my share of both manuals as well as stack traces that didn't make much sense.
This is my experience with Clojure stack traces ~60-75% of the time. Perhaps it is a symptom of functional programming? A lot of function passing and anonymous functions make it difficult to generate a meaningful stack trace.
Ask HN: What is your best advice for a junior software developer?
301–310 of 460 posts
Re: Ask HN: What is your best advice for a junior software developer?
#302Re: Ask HN: What is your best advice for a junior software developer?
#303Read the error messages. Reread them. Extract every piece of information from them. Never close an error popup without having read and understood what it means. Always read stack traces when you're blessed enough to have them. 100% of the juniors (and an awful lot of seniors) I've ever trained simply ignore those and then come ask for help debugging. 99% of the time, the explanation for their problem is literally the…
Ok, I'm strictly a hobby developer so I don't really have co-workers to go ask for help. Do people really not read error messages? That boggles my mind. How would you ever figure out what went wrong? I mean, how could anyone ever learn to program well enough to get a job as a professional programmer without knowing to do that?
The most common way I've seen people try to figure out what went wrong is sprinkling stuff like "console.log("Here1"), console.log("Here2") throughout the code until they figure out which "Here" statement wasn't printed, then they start making random changes to values until the error reflects the changes that they made, then they check stackoverflow, if there aren't any results, they'll paste the error message with no context, having learned nothing in the process. It's pretty common in any field where you can get by knowing "what" to do, vs "why" to do something. I've seen the same thing teaching Linux classes where someone throws up their hands and gives up because they tried to cat a file and it said "error: no such file or directory", but they just saw "error", and decided it was too difficult.
Re: Ask HN: What is your best advice for a junior software developer?
#304Read the error messages. Reread them. Extract every piece of information from them. Never close an error popup without having read and understood what it means. Always read stack traces when you're blessed enough to have them. 100% of the juniors (and an awful lot of seniors) I've ever trained simply ignore those and then come ask for help debugging. 99% of the time, the explanation for their problem is literally the…
Ok, I'm strictly a hobby developer so I don't really have co-workers to go ask for help. Do people really not read error messages? That boggles my mind. How would you ever figure out what went wrong? I mean, how could anyone ever learn to program well enough to get a job as a professional programmer without knowing to do that?
Re: Ask HN: What is your best advice for a junior software developer?
#305Earlier quoted context omitted.
Aren't young people allowed to, well, be young though? When you don't go to nightclubs, don't have friends to call at 1am and can't play guitar in your 400sqft apartment with neighbors on all sides of the world's thinnest walls, is it a terrible thing if coding all day and all night on relatively minor problems to make somebody else five figures a week is your primary source of excitement? Does it not beat alcohol an…
> Aren't young people allowed to, well, be young though? Working all-nighters to the point your health starts to suffer is not being young. It's exploitation the likes of which the chapters on the industrial revolution warn us about. More importantly, we as a society should actively discourage this sort of abuse. It makes no sense to let our health waste away just because a manager wants to boast about a target or a…
Re: Ask HN: What is your best advice for a junior software developer?
#306Save 25X your annual spending and you can retire. If you invest to earn 7%/yr (on avg), you can withdraw 4% forever. Read the book The Simple Path to Wealth, or the basics in this blog post. http://www.mrmoneymustache.com/2012/01/13/the-shockingly-sim...
Could anyone explain this a little for me, please? Does this mean you save 93% of your income and only use 7%? From the website, there is a graph that shows how many years you supposedly have to save for retirement but it does not take into account the actual amount you make. As a "junior" dev, if you save 97% of X peanuts you still have peanuts.
Re: Ask HN: What is your best advice for a junior software developer?
#307Treat people with respect. Sleep well. Take care of your body and your mental health. Try to turn any feelings of inadequacy or imposter syndrome into energy to push yourself forward and increase your skills and knowledge. We've all been there... multiple times. Learn to code fearlessly: Are you being asked to run queries on a production box? Ask if you can get a user with read-only permissions. Change crusty old cod…
This my favorite comment on this thread. Coding fearlessly is such a privilege/skill - makes a world of difference.
When I manage to get a team to create a code base with good tests it turns out that it's easy to change and resilient in the face of sudden requests for features.
A poor test infrastructure doesn't do this, building a good infrastructure is a skilled task. But worth it!
Re: Ask HN: What is your best advice for a junior software developer?
#308There is no better source of knowledge than solving software issues. You see it all in that backlog. Deployment issue, build issues, bug fixes, feature changes, merging problems, log files, web server configurations, DNS issues, certificate installations, database errors, database updates, connection issues, you name it. It is in there.
Once you feel comfortable with that backlog, look at the source code of your application and you will then ask your self, WHY IN THE WORLD WAS THIs BUILT THIS WAY?!?! you will find everything wrong with the application and that is a good feeling.
Start with Supporting an application before developing it.
Re: Ask HN: What is your best advice for a junior software developer?
#309Earlier quoted context omitted.
Related: Read the official documentation. I can’t count how many times junior folks have asked me things like, does FooBarFactory constructor take an array of ints or floats? Well, what does their documentation say? Sometimes the official documentation is crap and that’s a reasonable question, but usually the answers can be found in TFM.
I noticed a similar trend in JS dev: asking/looking for (video) tutorials instead of reading the official doc. Even when the doc is good and quick too read (React, Redux, Vue, etc).
Re: Ask HN: What is your best advice for a junior software developer?
#310Earlier quoted context omitted.
I really like your last point "whatever the computer is telling is true from the computer point of view". In a surprising number of coding interviews that I've conducted, I've seen a candidate write an incorrect solution that generates an exception and then attempt to figure out the error almost on first principles, rather than actually reading the exception carefully and thinking about what coding errors could have…
It isn't just a huge hint, most of the time it tells you exactly what the damn issue is. This discussion is blowing my mind. I am honestly speechless. IT GIVES YOU THE LINE NUMBER AND THE FUNCTION CALL AND THE REASON! Why would you ever even attempt to debug without parsing it?