Ask HN: I think My code isn't Good enough
1–10 of 97 posts
Re: Ask HN: I think My code isn't Good enough
#2Re: Ask HN: I think My code isn't Good enough
#3"I think you can tell a competent software developer from an incompetent one with a single interview question: 'What's the worst code you've seen recently?' If their answer isn't immediately and without any hesitation [the] two words 'My own.' then you should end the interview immediately."
Re: Ask HN: I think My code isn't Good enough
#4Note I am not promoting spaghetti code. If it's not blatantly incomprehensible (i.e. you abide to some common sense) and works, you are set.
Of course this is my view after having spent non-trivial amounts of time making code beautiful, modular and reusable instead of trying to solve the problem at hand. YMMV.
Re: Ask HN: I think My code isn't Good enough
#5Re: Ask HN: I think My code isn't Good enough
#6It seems possible you are being exposed to mentors that are being too harsh on you. Certainly you're being too harsh on yourself. Go forth boldly and code.
Take some time to read about _why's philosophy on coding and making mistakes. I think it would do you a world of good.
Re: Ask HN: I think My code isn't Good enough
#7Re: Ask HN: I think My code isn't Good enough
#8A few years ago I started working on a game, the best ever I thought. I was so clever with everything I thought and oh I wouldn't need to refactor because I would do it right from the start!
Of course I moved on and started to work on other things for a while and when I came back I thought it was horrible, almost unusable!
This happens all the time, though at a lesser extent, for me. When I notice something new, fresh, nice or beautiful way of doing things the old way is simple not good enough. Why did you ever do it that way?
Don't bother too much - it's normal and it shows that you're always evolving and getting better. And after all, you learn by doing mistakes not by doing everything beautiful and perfect from the start.
Re: Ask HN: I think My code isn't Good enough
#9The best thing I can suggest is expanding your horizon as far as possible. Your profile says you're a RoR/JS programmer. Go learn some Haskell (or any other functional language; I started with Racket) and you'll find a truly different way of looking at programming, one which will change your style forever.