Live data from Hacker News

Ask HN: How do you get better at coding?

news.ycombinator.com

31–40 of 73 posts

Re: Ask HN: How do you get better at coding?

#31
1. Write big enough programs of your own such that you experience them collapsing under their own weight. That forces you to see the consequences of your actions. Only then can you really learn how to structure things better.

2. Try to learn the underlying technologies thoroughly. For example, try writing a simple C compiler and linker. That will teach you about a lot of things that a lot of the programming world sits on top of.

Re: Ask HN: How do you get better at coding?

#32

I get better at coding by coding. No, really. You can read all the books, blog posts, open source code samples you want, but nothing will substitute writing code. I maintain a handful of side projects as well as write code daily for my job. Plus, I love it. Also, my side projects usually encompass something I have no idea how to do, which quickly elevates my skill level. I love learning, so it works for me.

I would add that it's also a iterative process: code, review, learn, and code some more. A continuing process

Re: Ask HN: How do you get better at coding?

#33
post #11

I get better at coding by coding. No, really. You can read all the books, blog posts, open source code samples you want, but nothing will substitute writing code. I maintain a handful of side projects as well as write code daily for my job. Plus, I love it. Also, my side projects usually encompass something I have no idea how to do, which quickly elevates my skill level. I love learning, so it works for me.

I think I "read" about programming for something like 15 years (books, blogs, HN, proggit, irc chat) I started actually coding seriously and properly the past 1-2 years. Easily learned a hundred-fold more by doing it, literally. I think too often I told myself I'm "not good enough to make something serious". And you know -- it was probably true. But that doesn't matter . Just start, things will fall into place, somet…

> I think too often I told myself I'm "not good enough to make something serious". And you know -- it was probably true. But that doesn't matter. Just start, things will fall into place, sometimes you'll fail, sometimes you won't. It's just the only way really.

it's not true, most "serious" things aren't that difficult or complex

Re: Ask HN: How do you get better at coding?

#35
I get better by giving myself some time to explore new topics. One recent example was giving myself "time" to learn Jest and writing more frontend unit tests. Took < 30 minutes to learn it and I was good to go, but we're all so busy sometimes we don't allow ourselves time to learn.

Re: Ask HN: How do you get better at coding?

#37

Earlier quoted context omitted.

Code reviews help a lot with that. At my current company we don't review so I've found myself getting complacent

I've found this too - I work much better when I know someone I respect will read my code.

Yes. Being able to give an opinion about code or code design and back it up with reasoned arguments (as opposed to dogmatic obedience) is part of becoming a good dev imo

Re: Ask HN: How do you get better at coding?

#38

1. Write code for side projects 2. Read others code for similar projects in same language. On #2, for example, if you are working on a todo list backend in python, try to find existing solutions for todo list backend in python. Then you can see what others using in their solutions and try to bring them into yours. I understand, this approach is not applicable for everything but I have found lots of gems this way.

Conversely, avoiding looking at what others have done and doing it yourself can help loads too.

Only when you get stuck and cant figure something out with your current knowledge set, should you venture to look at others solutions.

Or after you have completed your solution and are curious about what others have done. You might find a library that makes your life way easier, but had you started out using that library, you wouldn't have the best understanding of the nitty gritty details.

I will admit sometimes I get a little ambitious with what I want to do and end up looking at other solutions to see just how complex we have to go.

Re: Ask HN: How do you get better at coding?

#40

I get better at coding by coding. No, really. You can read all the books, blog posts, open source code samples you want, but nothing will substitute writing code. I maintain a handful of side projects as well as write code daily for my job. Plus, I love it. Also, my side projects usually encompass something I have no idea how to do, which quickly elevates my skill level. I love learning, so it works for me.

Yes, not just experience is important, but experimental experience. I learn so much less at work than I do on personal projects simply because I don't experiment as much. Unfortunately the realities of time and effort have caught up with me and I don't get to put nearly as much time into personal projects.
Post reply on HN