if you have a good debugger then start at the beginning and run it line by line. if a section looks understandable skip it.
Ask HN: How do you read code?
11–12 of 12 posts
Re: Ask HN: How do you read code?
#12If you have access to a whiteboard... List all of the directories (or classes, for a smaller project), and draw them as boxes on the board. Draw arrows between the boxes based on dependencies in the codebase (helps if you have someone already familiar). ... Now start at the bottom of the dependency graph, and browse the code at a medium level. If you are going to be working in this codebase, go back through and brows…
Thanks for the answer! It sounds like you're taking a bottom-up approach when reading code. Do you think we can use software to build this dependency graph and make it easier to read code?
For purposes of learning the code, it may not be worth automating the dependency graph. You will probably learn more from tracking it down than you would if it was pre-generated for you.