TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Ask HN: Things that have made you a better programmer

2 pointsby curious16over 2 years ago
&quot;Things&quot; is by intention ambiguous as it can vary from person to person. For someone it may be an enlightening course on Programming Languages; for someone else it can be a lengthy project they built from scratch. Or it maybe anything that doesn&#x27;t come to my mind at the moment but have helped you up your game as a programmer.<p>After all, programming is another form of design.

4 comments

simonblackover 2 years ago
Better variable names.<p>When I started programming, it was in BASIC. The drawback of BASIC was that variable names were restricted to one letter or one letter plus one digit. So &#x27;A&#x27;, &#x27;B&#x27;, or &#x27;A1&#x27;, &#x27;A2&#x27; and even in the same program you could have the numerical variable &#x27;A2&#x27; and the string variable &#x27;A2$&#x27;. Six months after you write a program with variable-names like these, it&#x27;s no good trying to maintain such a program because you have no clue what &#x27;A1&#x27;, &#x27;A2&#x27; and &#x27;A3&#x27; are at all. And you&#x27;re better off rewriting the whole program from scratch.<p>Then followed a stint with COBOL where I learned to use variable names such as &#x27;WEEKLY-WAGE-TAX-LEVEL&#x27; which are eminently readable and understandable, whether five minutes later or five months later, or even three decades later. I still have some COBOL source files on my archive partition that are very clear on what the program does and what the variables are for.<p>Since then, I have done my best to make sure that all my variable-names (and function-names) are picked to enable ease of maintenance.
terminal_dover 2 years ago
Thinking hard and pausing before writing: If you can suss out the pitfalls for some program before you write a significant amount of it, it&#x27;d save you a lot of time. The way you&#x27;ve learnt something can lead you to be stubborn about a certain process, which means you might have to &quot;hack&quot; your way through it -- I &quot;&quot;prototype&quot;&quot; code in an easier language before I start writing it. It doesn&#x27;t have to run in that language. I use lua for this purpose.<p>Take diligent notes: My system (in emacs) helps me out here. Taking a few seconds to look for a solution in your notes trumps going through a wild goose chase on the internet only to encounter links that you immediately half-recognize as something you tried six months ago when you had $issue. &quot;Quantified life&quot; stuff helps out here. Here&#x27;s a big protip: never delete your bash history.
kingkongjaffaover 2 years ago
CS50x got me from 0 to 1.<p>Reading about types and type systems have helped me mature, in I think a similar sense to gaining mathematical maturity when you start learning proofs for the first time.<p>It&#x27;s hard to beat working with a more experienced developer and following behind them and being able to ask them why they made the choices they did.
fbrncciover 2 years ago
During the pandemic, started taking 1-2 hour breaks in the middle of my workday to go outside and walk. It helped me detach from complex problems, and think about them differently.<p>A year ago that changed. Or I guess I optimized. Now I jog an hour before I start work. It just makes me feel so good ... And then around the time my mental batteries start to run out, I attend a hour long Muay Thai class. I find that after the class, I can think a lot clearer about problems faced before the class. That last hour of the workday, feels like I am cheating with a new burst of productivity.<p>This (very personal) approach has definitely made me a much better programmer. I can&#x27;t think about going back to just sitting there for 6-8 hours, trying to solve problems anymore. Or getting to work without being a mildly physically exhausted.