News for hackers. Stuff that matters.
Re:Ask HN: What is your best advice for a developer to write... by siscia on Wednesday June 29, 2016 @03:42PM (#12004215)
Think really hard about the problem you are solving.

First question to ask is always: Do I need to write some code or I can solve this problem using tools already here?

If you decide to write code, then start to think really hard.

What interface should I provide? The smallest the interface the better; and be aware that any kind of configuration your interface use increase exponentially the size of the interface itself.

Now you should experiment, take your time and be sure that the interface you are providing is the smallest possible, try to see the problem from another point of view, don't be afraid to throw away code (don't write test yet if not for experimental purpose, you don't even have the interface to test) and try to keep everything stateless and pure.

During this process is important to gather feedback from your peers, they may see problem that you don't.

Once you have decided what you are going to code, write it down.

Try to keep everything so simple that test will seems pointless, write those anyway.

Be slow, take your time for thinking, don't be afraid to throw code away.

Re:Ask HN: What is your best advice for a developer to write... by yitchelle on Wednesday June 29, 2016 @03:48PM (#12004261)
> Think really hard about the problem you are solving.

This is really good advice. Also think really hard about what is the real problem you are trying to solve and only write code to solve that problem.

The oxymoron is the best code you write is the code that you did not write.

Re:Ask HN: What is your best advice for a developer to write... by namelezz on Wednesday June 29, 2016 @03:53PM (#12004291)
> Think really hard about the problem you are solving.

How do you know you have thought hard enough?

Re:Ask HN: What is your best advice for a developer to write... by bbcbasic on Thursday June 30, 2016 @05:24AM (#12007428)
If your boss hasn't complained about how long you've spent thinking you haven't thought hard enough. /s
Re:Ask HN: What is your best advice for a developer to write... by 0xdeadbeefbabe on Wednesday June 29, 2016 @03:57PM (#12004335)
This would be a good SO question.
Re:Ask HN: What is your best advice for a developer to write... by shardinator on Thursday June 30, 2016 @11:28AM (#12009196)
It would be closed for being off-topic ;)