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: What are your tips for reading other people's code?

2 pointsby autogolover 8 years ago

2 comments

Eridrusover 8 years ago
Depends on how long you have, how unfamiliar the code&#x2F;build is and what the goal is, but spend as much time as reasonable getting tools to work first.<p>Make sure you can figure out what function is actually getting called when you see a function name. Tools like Source Insight can be useful if you need to get up and running quickly since they support very loose searching rules. I&#x27;ve also heard good things about SciTools Understand, but never used it myself.<p>The best thing though would be to get the software running in a way that you can debug it. Being able to step through code and see how data is modified and which particular implementation of an interface gets called, etc, can be very helpful.<p>Being able to exercise the code in question always makes it easier to understand because you can think about it in larger blocks than trying to form an picture of the larger goal line by line.
NigelRover 8 years ago
Read through some of the code with the original author. It may seem obvious and it&#x27;s not always possible, but when you can do this you can cut hours off the time it takes to understand the code and other code that the author wrote.<p>What you&#x27;ll get from this that would be more challenging on your own:<p>- design tradeoffs<p>- high level design<p>- the author&#x27;s coding patterns